root/src/noit_config.h.in

Revision c105913d38157700cbb9fbc7f0f6f8a7b18de103, 4.6 kB (checked in by Theo Schlossnagle <jesus@omniti.com>, 7 years ago)

compile on OpenBSD

  • 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_SYS_RESOURCE_H
49 #undef HAVE_LIBKERN_OSATOMIC_H
50 #undef HAVE_INT64_T
51 #undef HAVE_INTXX_T
52 #undef HAVE_LONG_LONG_INT
53 #undef HAVE_UINTXX_T
54 #undef HAVE_U_INT
55 #undef HAVE_U_INT64_T
56 #undef HAVE_U_INTXX_T
57 #define IFS_CH '/'
58
59 #ifdef HAVE_STRING_H
60 #include <string.h>
61 #endif
62 #ifdef HAVE_STDLIB_H
63 #include <stdlib.h>
64 #endif
65 #ifdef HAVE_SYS_PARAM_H
66 #include <sys/param.h>
67 #endif
68 #ifdef HAVE_SYS_TYPES_H
69 #include <sys/types.h>
70 #endif
71 #ifdef HAVE_SYS_STAT_H
72 #include <sys/stat.h>
73 #endif
74 #ifdef HAVE_SYS_RESOURCE_H
75 #include <sys/resource.h>
76 #endif
77
78 /* Kernel kqueue() support */
79 #undef HAVE_KQUEUE
80
81 /* The number of bytes in a char.  */
82 #undef SIZEOF_CHAR
83
84 /* The number of bytes in a int.  */
85 #undef SIZEOF_INT
86
87 /* The number of bytes in a size_t.  */
88 #undef SIZEOF_SIZE_T
89
90
91 /* The number of bytes in a long int.  */
92 #undef SIZEOF_LONG_INT
93
94 /* The number of bytes in a long long int.  */
95 #undef SIZEOF_LONG_LONG_INT
96
97 /* The number of bytes in a short int.  */
98 #undef SIZEOF_SHORT_INT
99
100 /* The number of bytes in a void *.  */
101 #undef SIZEOF_VOID_P
102
103 #ifndef HAVE_U_INT
104 typedef unsigned int u_int;
105 #endif
106
107 #undef HAVE_INTXX_T
108 #ifndef HAVE_INTXX_T
109 #if (SIZEOF_CHAR == 1)
110 typedef char int8_t;
111 #else
112 #error "8 bit int type not found."
113 #endif
114 #if (SIZEOF_SHORT_INT == 2)
115 typedef short int int16_t;
116 #else
117 #ifdef _CRAY
118 typedef long int16_t;
119 #else
120 #warning "16 bit int type not found."
121 #endif /* _CRAY */
122 #endif
123 #if (SIZEOF_INT == 4)
124 typedef int int32_t;
125 #else
126 #ifdef _CRAY
127 typedef long int32_t;
128 #else
129 #error "32 bit int type not found."
130 #endif /* _CRAY */
131 #endif
132 #endif
133
134 /* If sys/types.h does not supply u_intXX_t, supply them ourselves */
135 #ifndef HAVE_U_INTXX_T
136 #ifdef HAVE_UINTXX_T
137 typedef uint8_t u_int8_t;
138 typedef uint16_t u_int16_t;
139 typedef uint32_t u_int32_t;
140 #define HAVE_U_INTXX_T 1
141 #else
142 #if (SIZEOF_CHAR == 1)
143 typedef unsigned char u_int8_t;
144 #else
145 #error "8 bit int type not found."
146 #endif
147 #if (SIZEOF_SHORT_INT == 2)
148 typedef unsigned short int u_int16_t;
149 #else
150 #ifdef _CRAY
151 typedef unsigned long u_int16_t;
152 #else
153 #warning "16 bit int type not found."
154 #endif
155 #endif
156 #if (SIZEOF_INT == 4)
157 typedef unsigned int u_int32_t;
158 #else
159 #ifdef _CRAY
160 typedef unsigned long u_int32_t;
161 #else
162 #error "32 bit int type not found."
163 #endif
164 #endif
165 #endif
166 #endif
167
168 /* 64-bit types */
169 #ifndef HAVE_INT64_T
170 #if (SIZEOF_LONG_INT == 8)
171 typedef long int int64_t;
172 #define HAVE_INT64_T 1
173 #else
174 #if (SIZEOF_LONG_LONG_INT == 8)
175 typedef long long int int64_t;
176 #define HAVE_INT64_T 1
177 #define HAVE_LONG_LONG_INT
178 #endif
179 #endif
180 #endif
181 #ifndef HAVE_U_INT64_T
182 #if (SIZEOF_LONG_INT == 8)
183 typedef unsigned long int u_int64_t;
184 #define HAVE_U_INT64_T 1
185 #else
186 #if (SIZEOF_LONG_LONG_INT == 8)
187 typedef unsigned long long int u_int64_t;
188 #define HAVE_U_INT64_T 1
189 #endif
190 #endif
191 #endif
192
193 #endif
Note: See TracBrowser for help on using the browser.