diff options
Diffstat (limited to 'src/include/mhd_options.h')
-rw-r--r-- | src/include/mhd_options.h | 76 |
1 files changed, 76 insertions, 0 deletions
diff --git a/src/include/mhd_options.h b/src/include/mhd_options.h index a7fadfae..faefd328 100644 --- a/src/include/mhd_options.h +++ b/src/include/mhd_options.h | |||
@@ -192,5 +192,81 @@ | |||
192 | #endif /* MHD_HAVE_MHD_FUNC_ */ | 192 | #endif /* MHD_HAVE_MHD_FUNC_ */ |
193 | #endif | 193 | #endif |
194 | 194 | ||
195 | /* Un-define some HAVE_DECL_* macro if they equal zero. | ||
196 | This should allow safely use #ifdef in the code. | ||
197 | Define HAS_DECL_* macros only if matching HAVE_DECL_* macro | ||
198 | has non-zero value. Unlike HAVE_DECL_*, macros HAS_DECL_* | ||
199 | cannot have zero value. */ | ||
200 | #ifdef HAVE_DECL__SC_NPROCESSORS_ONLN | ||
201 | # if 0 == HAVE_DECL__SC_NPROCESSORS_ONLN | ||
202 | # undef HAVE_DECL__SC_NPROCESSORS_ONLN | ||
203 | # else /* 0 != HAVE_DECL__SC_NPROCESSORS_ONLN */ | ||
204 | # define HAS_DECL__SC_NPROCESSORS_ONLN 1 | ||
205 | # endif /* 0 != HAVE_DECL__SC_NPROCESSORS_ONLN */ | ||
206 | #endif /* HAVE_DECL__SC_NPROCESSORS_ONLN */ | ||
207 | |||
208 | #ifdef HAVE_DECL__SC_NPROCESSORS_CONF | ||
209 | # if 0 == HAVE_DECL__SC_NPROCESSORS_CONF | ||
210 | # undef HAVE_DECL__SC_NPROCESSORS_CONF | ||
211 | # else /* 0 != HAVE_DECL__SC_NPROCESSORS_CONF */ | ||
212 | # define HAS_DECL__SC_NPROCESSORS_CONF 1 | ||
213 | # endif /* 0 != HAVE_DECL__SC_NPROCESSORS_CONF */ | ||
214 | #endif /* HAVE_DECL__SC_NPROCESSORS_CONF */ | ||
215 | |||
216 | #ifdef HAVE_DECL__SC_NPROC_ONLN | ||
217 | # if 0 == HAVE_DECL__SC_NPROC_ONLN | ||
218 | # undef HAVE_DECL__SC_NPROC_ONLN | ||
219 | # else /* 0 != HAVE_DECL__SC_NPROC_ONLN */ | ||
220 | # define HAS_DECL__SC_NPROC_ONLN 1 | ||
221 | # endif /* 0 != HAVE_DECL__SC_NPROC_ONLN */ | ||
222 | #endif /* HAVE_DECL__SC_NPROC_ONLN */ | ||
223 | |||
224 | #ifdef HAVE_DECL__SC_CRAY_NCPU | ||
225 | # if 0 == HAVE_DECL__SC_CRAY_NCPU | ||
226 | # undef HAVE_DECL__SC_CRAY_NCPU | ||
227 | # else /* 0 != HAVE_DECL__SC_CRAY_NCPU */ | ||
228 | # define HAS_DECL__SC_CRAY_NCPU 1 | ||
229 | # endif /* 0 != HAVE_DECL__SC_CRAY_NCPU */ | ||
230 | #endif /* HAVE_DECL__SC_CRAY_NCPU */ | ||
231 | |||
232 | #ifdef HAVE_DECL_CTL_HW | ||
233 | # if 0 == HAVE_DECL_CTL_HW | ||
234 | # undef HAVE_DECL_CTL_HW | ||
235 | # else /* 0 != HAVE_DECL_CTL_HW */ | ||
236 | # define HAS_DECL_CTL_HW 1 | ||
237 | # endif /* 0 != HAVE_DECL_CTL_HW */ | ||
238 | #endif /* HAVE_DECL_CTL_HW */ | ||
239 | |||
240 | #ifdef HAVE_DECL_HW_NCPUONLINE | ||
241 | # if 0 == HAVE_DECL_HW_NCPUONLINE | ||
242 | # undef HAVE_DECL_HW_NCPUONLINE | ||
243 | # else /* 0 != HAVE_DECL_HW_NCPUONLINE */ | ||
244 | # define HAS_DECL_HW_NCPUONLINE 1 | ||
245 | # endif /* 0 != HAVE_DECL_HW_NCPUONLINE */ | ||
246 | #endif /* HAVE_DECL_HW_NCPUONLINE */ | ||
247 | |||
248 | #ifdef HAVE_DECL_HW_AVAILCPU | ||
249 | # if 0 == HAVE_DECL_HW_AVAILCPU | ||
250 | # undef HAVE_DECL_HW_AVAILCPU | ||
251 | # else /* 0 != HAVE_DECL_HW_AVAILCPU */ | ||
252 | # define HAS_DECL_HW_AVAILCPU 1 | ||
253 | # endif /* 0 != HAVE_DECL_HW_AVAILCPU */ | ||
254 | #endif /* HAVE_DECL_HW_AVAILCPU */ | ||
255 | |||
256 | #ifdef HAVE_DECL_HW_NCPU | ||
257 | # if 0 == HAVE_DECL_HW_NCPU | ||
258 | # undef HAVE_DECL_HW_NCPU | ||
259 | # else /* 0 != HAVE_DECL_HW_NCPU */ | ||
260 | # define HAS_DECL_HW_NCPU 1 | ||
261 | # endif /* 0 != HAVE_DECL_HW_NCPU */ | ||
262 | #endif /* HAVE_DECL_HW_NCPU */ | ||
263 | |||
264 | #ifdef HAVE_DECL_CPU_SETSIZE | ||
265 | # if 0 == HAVE_DECL_CPU_SETSIZE | ||
266 | # undef HAVE_DECL_CPU_SETSIZE | ||
267 | # else /* 0 != HAVE_DECL_CPU_SETSIZE */ | ||
268 | # define HAS_DECL_CPU_SETSIZE 1 | ||
269 | # endif /* 0 != HAVE_DECL_CPU_SETSIZE */ | ||
270 | #endif /* HAVE_DECL_CPU_SETSIZE */ | ||
195 | 271 | ||
196 | #endif /* MHD_OPTIONS_H */ | 272 | #endif /* MHD_OPTIONS_H */ |