forked from tbarbette/fastclick
-
Notifications
You must be signed in to change notification settings - Fork 0
/
config-userlevel.h.in
362 lines (262 loc) · 9.47 KB
/
config-userlevel.h.in
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
/* Process this file with configure to produce config-userlevel.h. -*- mode: c -*- */
#ifndef CLICK_CONFIG_USERLEVEL_H
#define CLICK_CONFIG_USERLEVEL_H
/* Define if you have the __thread storage class specifier. */
#undef HAVE___THREAD_STORAGE_CLASS
/* Define if accept() uses socklen_t. */
#undef HAVE_ACCEPT_SOCKLEN_T
/* Define if kqueue() may be used to wait for file descriptor events. */
#undef HAVE_ALLOW_KQUEUE
/* Define if poll() may be used to wait for file descriptor events. */
#undef HAVE_ALLOW_POLL
/* Define if select() may be used to wait for file descriptor events. */
#undef HAVE_ALLOW_SELECT
/* Define if <pcap.h> uses bpf_timeval. */
#undef HAVE_BPF_TIMEVAL
/* Define if you have the <byteswap.h> header file. */
#undef HAVE_BYTESWAP_H
/* Define if you have the clock_gettime function. */
#undef HAVE_CLOCK_GETTIME
/* Define to 1 if you have the declaration
of 'clock_gettime', and to 0 if you don't. */
#undef HAVE_DECL_CLOCK_GETTIME
/* Define to 1 if you have the declaration
of 'madvise', and to 0 if you don't. */
#undef HAVE_DECL_MADVISE
/* Define to 1 if you have the declaration
of 'pcap_setnonblock', and to 0 if you don't. */
#undef HAVE_DECL_PCAP_SETNONBLOCK
/* Define if you have the <dlfcn.h> header file. */
#undef HAVE_DLFCN_H
/* Define if you have the <nuda.h> header file. */
#undef HAVE_NUMA
/* Define if dynamic linking is possible. */
#undef HAVE_DYNAMIC_LINKING
/* Define if you have the <execinfo.h> header file. */
#undef HAVE_EXECINFO_H
/* Define if you have the ffs function. */
#undef HAVE_FFS
/* Define if you have the ffsl function. */
#undef HAVE_FFSL
/* Define if you have the ffsll function. */
#undef HAVE_FFSLL
/* Floating point arithmetic is allowed. */
#define HAVE_FLOAT_TYPES 1
/* Define if you have the <grp.h> header file. */
#undef HAVE_GRP_H
/* Define if the last argument to EV_SET has pointer type. */
#undef HAVE_EV_SET_UDATA_POINTER
/* Define if 'struct if_data' has an 'ifi_datalen' member. */
#undef HAVE_IF_DATA_IFI_DATALEN
/* Define if you have the <ifaddrs.h> header file. */
#undef HAVE_IFADDRS_H
/* Define if 'int64_t' is typedefed to 'long' at user level. */
#undef HAVE_INT64_IS_LONG_USERLEVEL
/* Define if 'int64_t' is typedefed to 'long long' at user level. */
#undef HAVE_INT64_IS_LONG_LONG_USERLEVEL
/* Define if you have the <inttypes.h> header file. */
#undef HAVE_INTTYPES_H
/* Define if you have the kqueue function. */
#undef HAVE_KQUEUE
/* Define if your C library contains large file support. */
#undef HAVE_LARGE_FILE_SUPPORT
/* Define if you have the <linux/if_tun.h> header file. */
#undef HAVE_LINUX_IF_TUN_H
/* Define if you have the madvise function. */
#undef HAVE_MADVISE
/* Define if you have the mmap function. */
#undef HAVE_MMAP
/* Define if you have the <net/bpf.h> header file. */
#undef HAVE_NET_BPF_H
/* Define if you have the <net/if_dl.h> header file. */
#undef HAVE_NET_IF_DL_H
/* Define if you have the <net/if_tap.h> header file. */
#undef HAVE_NET_IF_TAP_H
/* Define if you have the <net/if_tun.h> header file. */
#undef HAVE_NET_IF_TUN_H
/* Define if you have the <net/if_types.h> header file. */
#undef HAVE_NET_IF_TYPES_H
/* Define if you have the <netdb.h> header file. */
#undef HAVE_NETDB_H
/* Define if you have the <netpacket/packet.h> header file. */
#undef HAVE_NETPACKET_PACKET_H
/* Define if <new.h> exists and works. */
#undef HAVE_NEW_H
/* Define if <new> exists and works. */
#undef HAVE_NEW_HDR
/* Define if you have -lpcap and pcap.h. */
#undef HAVE_PCAP
/* Define if you have the pcap_inject function. */
#undef HAVE_PCAP_INJECT
/* Define if you have the pcap_sendpacket function. */
#undef HAVE_PCAP_SENDPACKET
/* Define if you have the pcap_setdirection function. */
#undef HAVE_PCAP_SETDIRECTION
/* Define if you have the pcap_setnonblock function. */
#undef HAVE_PCAP_SETNONBLOCK
/* Define if you have the pcap_set_immediate_mode function. */
#undef HAVE_PCAP_SET_IMMEDIATE_MODE
/* Define if you have -lproper and prop.h, and proper operations should be
preferred to their non-proper counterparts. */
#undef HAVE_PROPER
/* Define if you have a non-emulated <poll.h> header file. */
#undef HAVE_POLL_H
/* Define if you have the pselect function. */
#undef HAVE_PSELECT
/* Placement new is always provided below. */
#define HAVE_PLACEMENT_NEW 1
/* Define to 1 if you have the declaration
of 'pthread_setaffinity_np', and to 0 if you don't. */
#undef HAVE_DECL_PTHREAD_SETAFFINITY_NP
/* Define if you have the <pwd.h> header file. */
#undef HAVE_PWD_H
/* Define if you have the random function. */
#undef HAVE_RANDOM
/* Define if you have the sigaction function. */
#undef HAVE_SIGACTION
/* Define if you have the snprintf function. */
#undef HAVE_SNPRINTF
/* Define if 'struct sockaddr_in' has a 'sin_len' member. */
#undef HAVE_SOCKADDR_IN_SIN_LEN
/* Define if you have the strerror function. */
#undef HAVE_STRERROR
/* Define if you have the <strings.h> header file. */
#undef HAVE_STRINGS_H
/* Define if you have the strnlen function. */
#undef HAVE_STRNLEN
/* Define if you have the strtof function. */
#undef HAVE_STRTOF
/* Define if you have the strtold function. */
#undef HAVE_STRTOLD
/* Define if you have the strtoul function. */
#undef HAVE_STRTOUL
/* Define if you have the <sys/event.h> header file. */
#undef HAVE_SYS_EVENT_H
/* Define if you have the <sys/mman.h> header file. */
#undef HAVE_SYS_MMAN_H
/* Define if you have the tcgetpgrp function. */
#undef HAVE_TCGETPGRP
/* Define if you have the <termio.h> header file. */
#undef HAVE_TERMIO_H
/* Define if you have u_intXX_t types but not uintXX_t types. */
#undef HAVE_U_INT_TYPES
/* Define if you have the <unistd.h> header file. */
#undef HAVE_UNISTD_H
/* Define if a Click user-level driver might run multiple threads. */
#undef HAVE_USER_MULTITHREAD
/* Define if Zero-copy is enabled. */
#undef HAVE_ZEROCOPY
/* Define if Netmap support is enabled. */
#undef HAVE_NETMAP
/* Define if you use only netmap buffer as data buffer. */
#undef HAVE_NETMAP_PACKET_POOL
/* Define if a Click user-level driver uses Intel DPDK. */
#undef HAVE_DPDK
/* Define if you use only DPDK buffer as data buffer. */
#undef HAVE_DPDK_PACKET_POOL
/* Define if a Click user-level driver manages Intel DPDK packet pools. */
#undef CLICK_PACKET_USE_DPDK
/* Define if Click should use Valgrind client requests. */
#undef HAVE_VALGRIND
/* Define if you have the <valgrind/memcheck.h> header file. */
#undef HAVE_VALGRIND_MEMCHECK_H
/* Define if you have the vsnprintf function. */
#undef HAVE_VSNPRINTF
/* The size of a `click_jiffies_t', as computed by sizeof. */
#define SIZEOF_CLICK_JIFFIES_T SIZEOF_INT
/* The size of a `off_t', as computed by sizeof. */
#undef SIZEOF_OFF_T
/* Set feature test macros before anything is included. */
#if HAVE_LARGE_FILE_SUPPORT && HAVE_INT64_TYPES
# if defined(_FILE_OFFSET_BITS) && _FILE_OFFSET_BITS != 64
# error "bad _FILE_OFFSET_BITS, did you #include <click/config.h> first?"
# endif
# define _LARGEFILE_SOURCE 1
# define _FILE_OFFSET_BITS 64
#endif
#ifdef __APPLE__
# define _DARWIN_UNLIMITED_SELECT 1
#endif
/* Include integer type definitions. */
#ifdef HAVE_INTTYPES_H
# include <inttypes.h>
#endif
#include <sys/types.h>
/* Define uint types in terms of u_int types, if necessary. */
#ifdef HAVE_U_INT_TYPES
typedef u_int8_t uint8_t;
typedef u_int16_t uint16_t;
typedef u_int32_t uint32_t;
# ifdef HAVE_INT64_TYPES
typedef u_int64_t uint64_t;
# endif
typedef long intptr_t; /* XXX? */
typedef unsigned long uintptr_t;
#endif
/* Define HAVE_INT64_IS_LONG based on HAVE_INT64_IS_LONG_USERLEVEL. */
#ifdef HAVE_INT64_IS_LONG_USERLEVEL
# define HAVE_INT64_IS_LONG HAVE_INT64_IS_LONG_USERLEVEL
#endif
/* Define HAVE_INT64_IS_LONG_LONG based on HAVE_INT64_IS_LONG_LONG_USERLEVEL. */
#ifdef HAVE_INT64_IS_LONG_LONG_USERLEVEL
# define HAVE_INT64_IS_LONG_LONG HAVE_INT64_IS_LONG_LONG_USERLEVEL
#endif
/* If 64-bit integers exist, then 64-bit divide exists. */
#ifdef HAVE_INT64_TYPES
# define HAVE_INT64_DIVIDE 1
#endif
/* Define HAVE_MULTITHREAD based on HAVE_USER_MULTITHREAD. */
#ifdef HAVE_USER_MULTITHREAD
# define HAVE_MULTITHREAD HAVE_USER_MULTITHREAD
#endif
/* Define HAVE_USE_CLOCK_GETTIME if the clock_gettime function is usable. */
#ifndef HAVE_USE_CLOCK_GETTIME
# if HAVE_DECL_CLOCK_GETTIME && HAVE_CLOCK_GETTIME
# define HAVE_USE_CLOCK_GETTIME 1
# endif
#endif
/* Include assert macro. */
#include <assert.h>
/* Define likely and unlikely macros. */
#if __GNUC__ >= 3
# define likely(x) __builtin_expect(!!(x), 1)
# define unlikely(x) __builtin_expect(!!(x), 0)
#else
# define likely(x) (x)
# define unlikely(x) (x)
#endif
/* Define if mmap is allowed. */
#if defined(HAVE_SYS_MMAN_H) && defined(HAVE_MMAP)
# define ALLOW_MMAP 1
#endif
/* Prototype strerror if we don't have it. */
#ifndef HAVE_STRERROR
char *strerror(int errno);
#endif
/* Use nanosecond-granularity timestamps if they are enabled. */
#if HAVE_NANOTIMESTAMP_ENABLED
# define TIMESTAMP_NANOSEC 1
# define HAVE_NANOTIMESTAMP 1 /* Deprecated */
#endif
#ifdef __cplusplus
/* Provide placement new. */
#if HAVE_NEW_HDR
# include <new>
#elif HAVE_NEW_H
# include <new.h>
#else
inline void *operator new(size_t, void *v) { return v; }
#endif
/* Prototype madvise if we have it, but not the prototype. */
#if ALLOW_MMAP && HAVE_MADVISE && !HAVE_DECL_MADVISE
extern "C" int madvise(void *addr, size_t len, int behav);
#endif
/* Define macros that surround Click declarations. */
#ifndef CLICK_DECLS
# define CLICK_DECLS /* */
# define CLICK_ENDDECLS /* */
# define CLICK_USING_DECLS /* */
# define CLICK_NAME(name) ::name
#endif
#endif /* __cplusplus */
#endif /* CLICK_CONFIG_USERLEVEL_H */