config.h.in 4.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269
  1. /************************************************************************
  2. *
  3. * NRPE Common Header File
  4. * Copyright (c) 1999-2007 Ethan Galstad (nagios@nagios.org)
  5. * Last Modified: 11-23-2007
  6. *
  7. * License:
  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; either version 2 of the License, or
  12. * (at your option) any later version.
  13. *
  14. * This program is distributed in the hope that it will be useful,
  15. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  16. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  17. * GNU General Public License for more details.
  18. *
  19. * You should have received a copy of the GNU General Public License
  20. * along with this program; if not, write to the Free Software
  21. * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  22. ************************************************************************/
  23. #ifndef _CONFIG_H
  24. #define _CONFIG_H
  25. #include <stdio.h>
  26. #include <stdlib.h>
  27. #define DEFAULT_SERVER_PORT @nrpe_port@ /* default port to use */
  28. #define NRPE_LOG_FACILITY @log_facility@
  29. #undef ENABLE_COMMAND_ARGUMENTS
  30. #undef ENABLE_BASH_COMMAND_SUBSTITUTION
  31. #undef socklen_t
  32. #undef HAVE_GETOPT_LONG
  33. #undef HAVE_LIBWRAP
  34. #undef STDC_HEADERS
  35. #undef HAVE_STRDUP
  36. #undef HAVE_STRSTR
  37. #undef HAVE_STRTOUL
  38. #undef HAVE_STRTOK_R
  39. #undef HAVE_INITGROUPS
  40. #undef HAVE_CLOSESOCKET
  41. #undef HAVE_SIGACTION
  42. #undef HAVE_RFC931_TIMEOUT
  43. #undef SIZEOF_INT
  44. #undef SIZEOF_SHORT
  45. #undef SIZEOF_LONG
  46. /* #undef const */
  47. #undef USE_SSL_DH
  48. /* stupid stuff for u_int32_t */
  49. #undef U_INT32_T_IS_USHORT
  50. #undef U_INT32_T_IS_UINT
  51. #undef U_INT32_T_IS_ULONG
  52. #undef U_INT32_T_IS_UINT32_T
  53. #ifdef U_INT32_T_IS_USHORT
  54. typedef unsigned short u_int32_t;
  55. #endif
  56. #ifdef U_INT32_T_IS_ULONG
  57. typedef unsigned long u_int32_t;
  58. #endif
  59. #ifdef U_INT32_T_IS_UINT
  60. typedef unsigned int u_int32_t;
  61. #endif
  62. #ifdef U_INT32_T_IS_UINT32_t
  63. typedef uint32_t u_int32_t;
  64. #endif
  65. /* stupid stuff for int32_t */
  66. #undef INT32_T_IS_SHORT
  67. #undef INT32_T_IS_INT
  68. #undef INT32_T_IS_LONG
  69. #ifdef INT32_T_IS_USHORT
  70. typedef short int32_t;
  71. #endif
  72. #ifdef INT32_T_IS_ULONG
  73. typedef long int32_t;
  74. #endif
  75. #ifdef INT32_T_IS_UINT
  76. typedef int int32_t;
  77. #endif
  78. /***** ASPRINTF() AND FRIENDS *****/
  79. #undef HAVE_VSNPRINTF
  80. #undef HAVE_SNPRINTF
  81. #undef HAVE_ASPRINTF
  82. #undef HAVE_VASPRINTF
  83. #undef HAVE_C99_VSNPRINTF
  84. #undef HAVE_VA_COPY
  85. #undef HAVE___VA_COPY
  86. #define SOCKET_SIZE_TYPE ""
  87. #define GETGROUPS_T ""
  88. #define RETSIGTYPE ""
  89. #undef HAVE_STRUCT_SOCKADDR_STORAGE
  90. /* Use seteuid() or setresuid() depending on the platform */
  91. #undef SETEUID
  92. #undef HAVE_GETOPT_H
  93. #ifdef HAVE_GETOPT_H
  94. #include <getopt.h>
  95. #endif
  96. #undef HAVE_STRINGS_H
  97. #undef HAVE_STRING_H
  98. #ifdef HAVE_STRINGS_H
  99. #include <strings.h>
  100. #endif
  101. #ifdef HAVE_STRINGS_H
  102. #include <string.h>
  103. #endif
  104. #undef HAVE_UNISTD_H
  105. #ifdef HAVE_UNISTD_H
  106. #include <unistd.h>
  107. #endif
  108. #undef HAVE_SIGNAL_H
  109. #ifdef HAVE_SIGNAL_H
  110. #include <signal.h>
  111. #endif
  112. #undef HAVE_SYSLOG_H
  113. #ifdef HAVE_SYSLOG_H
  114. #include <syslog.h>
  115. #endif
  116. #undef HAVE_SYS_STAT_H
  117. #ifdef HAVE_SYS_STAT_H
  118. #include <sys/stat.h>
  119. #endif
  120. #undef HAVE_FCNTL_H
  121. #ifdef HAVE_FCNTL_H
  122. #include <fcntl.h>
  123. #endif
  124. #undef HAVE_SYS_TYPES_H
  125. #ifdef HAVE_SYS_TYPES_H
  126. #include <sys/types.h>
  127. #endif
  128. #undef HAVE_SYS_WAIT_H
  129. #ifdef HAVE_SYS_WAIT_H
  130. #include <sys/wait.h>
  131. #endif
  132. #ifndef WEXITSTATUS
  133. # define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
  134. #endif
  135. #ifndef WIFEXITED
  136. # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
  137. #endif
  138. #undef HAVE_ERRNO_H
  139. #ifdef HAVE_ERRNO_H
  140. #include <errno.h>
  141. #endif
  142. /* needed for the time_t structures we use later... */
  143. #undef TIME_WITH_SYS_TIME
  144. #undef HAVE_SYS_TIME_H
  145. #if TIME_WITH_SYS_TIME
  146. # include <sys/time.h>
  147. # include <time.h>
  148. #else
  149. # if HAVE_SYS_TIME_H
  150. # include <sys/time.h>
  151. # else
  152. # include <time.h>
  153. # endif
  154. #endif
  155. #undef HAVE_SYS_SOCKET_H
  156. #ifdef HAVE_SYS_SOCKET_H
  157. #include <sys/socket.h>
  158. #endif
  159. /* Define to 'int' if <sys/socket.h> does not define */
  160. #undef socklen_t
  161. #undef HAVE_SOCKET_H
  162. #ifdef HAVE_SOCKET_H
  163. #include <socket.h>
  164. #endif
  165. #undef HAVE_TCPD_H
  166. #ifdef HAVE_TCPD_H
  167. #include <tcpd.h>
  168. #endif
  169. #undef HAVE_NETINET_IN_H
  170. #ifdef HAVE_NETINET_IN_H
  171. #include <netinet/in.h>
  172. #endif
  173. #undef HAVE_ARPA_INET_H
  174. #ifdef HAVE_ARPA_INET_H
  175. #include <arpa/inet.h>
  176. #endif
  177. #undef HAVE_NETDB_H
  178. #ifdef HAVE_NETDB_H
  179. #include <netdb.h>
  180. #endif
  181. #undef HAVE_CTYPE_H
  182. #ifdef HAVE_CTYPE_H
  183. #include <ctype.h>
  184. #endif
  185. #undef HAVE_PWD_H
  186. #ifdef HAVE_PWD_H
  187. #include <pwd.h>
  188. #endif
  189. #undef HAVE_GRP_H
  190. #ifdef HAVE_GRP_H
  191. #include <grp.h>
  192. #endif
  193. #undef HAVE_DIRENT_H
  194. #ifdef HAVE_DIRENT_H
  195. #include <dirent.h>
  196. #endif
  197. #undef HAVE_SSL
  198. #ifdef HAVE_SSL
  199. #include <rsa.h>
  200. #include <crypto.h>
  201. # ifdef USE_SSL_DH
  202. #include <dh.h>
  203. # endif
  204. #include <pem.h>
  205. #include <ssl.h>
  206. #include <err.h>
  207. #include <rand.h>
  208. #endif
  209. #undef HAVE_KRB5_H
  210. #ifdef HAVE_KRB5_H
  211. #include <krb5.h>
  212. #endif
  213. #undef HAVE_INTTYPES_H
  214. #undef HAVE_STDINT_H
  215. #ifdef HAVE_INTTYPES_H
  216. #include <inttypes.h>
  217. #else
  218. #ifdef HAVE_STDINT_H
  219. #include <stdint.h>
  220. #endif
  221. #endif
  222. #endif