root/src/noit_config.h.in

Revision cd1ab55918856e8682710ede8ef2e44377887173, 4.4 kB (checked in by Theo Schlossnagle <jesus@omniti.com>, 6 years ago)

more work on the kqueue stuff

  • Property mode set to 100644
Line 
1 /*
2  * Copyright (c) 2005-2007, OmniTI Computer Consulting, Inc.
3  * All rights reserved.
4  *
5  * Redistribution and use in source and binary forms, with or without
6  * modification, are permitted provided that the following conditions are
7  * met:
8  *
9  *    * Redistributions of source code must retain the above copyright
10  *      notice, this list of conditions and the following disclaimer.
11  *    * Redistributions in binary form must reproduce the above
12  *      copyright notice, this list of conditions and the following
13  *      disclaimer in the documentation and/or other materials provided
14  *      with the distribution.
15  *    * Neither the name OmniTI Computer Consulting, Inc. nor the names
16  *      of its contributors may be used to endorse or promote products
17  *      derived from this software without specific prior written
18  *      permission.
19  *
20  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
21  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
22  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
23  * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
24  * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
25  * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
26  * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
27  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
28  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
29  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
30  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
31  */
32
33 #ifndef __NOIT_CONFIG_H
34 #define __NOIT_CONFIG_H
35
36 /* define inline unless that is what the compiler already calls it. */
37 #undef inline
38
39 #undef HAVE_FCNTL_H
40 #undef HAVE_SYS_TYPES_H
41 #undef HAVE_DIRENT_H
42 #undef HAVE_ERRNO_H
43 #undef HAVE_STRING_H
44 #undef HAVE_STDLIB_H
45 #undef HAVE_SYS_PARAM_H
46 #undef HAVE_TIME_H
47 #undef HAVE_SYS_STAT_H
48 #undef HAVE_LIBKERN_OSATOMIC_H
49 #define IFS_CH '/'
50
51 #ifdef HAVE_STRING_H
52 #include <string.h>
53 #endif
54 #ifdef HAVE_STDLIB_H
55 #include <stdlib.h>
56 #endif
57 #ifdef HAVE_SYS_PARAM_H
58 #include <sys/param.h>
59 #endif
60 #ifdef HAVE_SYS_TYPES_H
61 #include <sys/types.h>
62 #endif
63 #ifdef HAVE_SYS_STAT_H
64 #include <sys/stat.h>
65 #endif
66
67 /* Kernel kqueue() support */
68 #undef HAVE_KQUEUE
69
70 /* The number of bytes in a char.  */
71 #undef SIZEOF_CHAR
72
73 /* The number of bytes in a int.  */
74 #undef SIZEOF_INT
75
76 /* The number of bytes in a size_t.  */
77 #undef SIZEOF_SIZE_T
78
79
80 /* The number of bytes in a long int.  */
81 #undef SIZEOF_LONG_INT
82
83 /* The number of bytes in a long long int.  */
84 #undef SIZEOF_LONG_LONG_INT
85
86 /* The number of bytes in a short int.  */
87 #undef SIZEOF_SHORT_INT
88
89 /* The number of bytes in a void *.  */
90 #undef SIZEOF_VOID_P
91
92 #ifndef HAVE_U_INT
93 typedef unsigned int u_int;
94 #endif
95
96 #undef HAVE_INTXX_T
97 #ifndef HAVE_INTXX_T
98 #if (SIZEOF_CHAR == 1)
99 typedef char int8_t;
100 #else
101 #error "8 bit int type not found."
102 #endif
103 #if (SIZEOF_SHORT_INT == 2)
104 typedef short int int16_t;
105 #else
106 #ifdef _CRAY
107 typedef long int16_t;
108 #else
109 #warning "16 bit int type not found."
110 #endif /* _CRAY */
111 #endif
112 #if (SIZEOF_INT == 4)
113 typedef int int32_t;
114 #else
115 #ifdef _CRAY
116 typedef long int32_t;
117 #else
118 #error "32 bit int type not found."
119 #endif /* _CRAY */
120 #endif
121 #endif
122
123 /* If sys/types.h does not supply u_intXX_t, supply them ourselves */
124 #ifndef HAVE_U_INTXX_T
125 #ifdef HAVE_UINTXX_T
126 typedef uint8_t u_int8_t;
127 typedef uint16_t u_int16_t;
128 typedef uint32_t u_int32_t;
129 #define HAVE_U_INTXX_T 1
130 #else
131 #if (SIZEOF_CHAR == 1)
132 typedef unsigned char u_int8_t;
133 #else
134 #error "8 bit int type not found."
135 #endif
136 #if (SIZEOF_SHORT_INT == 2)
137 typedef unsigned short int u_int16_t;
138 #else
139 #ifdef _CRAY
140 typedef unsigned long u_int16_t;
141 #else
142 #warning "16 bit int type not found."
143 #endif
144 #endif
145 #if (SIZEOF_INT == 4)
146 typedef unsigned int u_int32_t;
147 #else
148 #ifdef _CRAY
149 typedef unsigned long u_int32_t;
150 #else
151 #error "32 bit int type not found."
152 #endif
153 #endif
154 #endif
155 #endif
156
157 /* 64-bit types */
158 #ifndef HAVE_INT64_T
159 #if (SIZEOF_LONG_INT == 8)
160 typedef long int int64_t;
161 #define HAVE_INT64_T 1
162 #else
163 #if (SIZEOF_LONG_LONG_INT == 8)
164 typedef long long int int64_t;
165 #define HAVE_INT64_T 1
166 #define HAVE_LONG_LONG_INT
167 #endif
168 #endif
169 #endif
170 #ifndef HAVE_U_INT64_T
171 #if (SIZEOF_LONG_INT == 8)
172 typedef unsigned long int u_int64_t;
173 #define HAVE_U_INT64_T 1
174 #else
175 #if (SIZEOF_LONG_LONG_INT == 8)
176 typedef unsigned long long int u_int64_t;
177 #define HAVE_U_INT64_T 1
178 #endif
179 #endif
180 #endif
181
182 #endif
Note: See TracBrowser for help on using the browser.