precompiled.hpp 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134
  1. /*
  2. Copyright (c) 2007-2016 Contributors as noted in the AUTHORS file
  3. This file is part of libzmq, the ZeroMQ core engine in C++.
  4. libzmq is free software; you can redistribute it and/or modify it under
  5. the terms of the GNU Lesser General Public License (LGPL) as published
  6. by the Free Software Foundation; either version 3 of the License, or
  7. (at your option) any later version.
  8. As a special exception, the Contributors give you permission to link
  9. this library with independent modules to produce an executable,
  10. regardless of the license terms of these independent modules, and to
  11. copy and distribute the resulting executable under terms of your choice,
  12. provided that you also meet, for each linked independent module, the
  13. terms and conditions of the license of that module. An independent
  14. module is a module which is not derived from or based on this library.
  15. If you modify this library, you must extend this exception to your
  16. version of the library.
  17. libzmq is distributed in the hope that it will be useful, but WITHOUT
  18. ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  19. FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
  20. License for more details.
  21. You should have received a copy of the GNU Lesser General Public License
  22. along with this program. If not, see <http://www.gnu.org/licenses/>.
  23. */
  24. #ifndef __ZMQ_PRECOMPILED_HPP_INCLUDED__
  25. #define __ZMQ_PRECOMPILED_HPP_INCLUDED__
  26. // On AIX platform, poll.h has to be included first to get consistent
  27. // definition of pollfd structure (AIX uses 'reqevents' and 'retnevents'
  28. // instead of 'events' and 'revents' and defines macros to map from POSIX-y
  29. // names to AIX-specific names).
  30. // zmq.h must be included *after* poll.h for AIX to build properly.
  31. // precompiled.hpp includes include/zmq.h
  32. #if defined ZMQ_POLL_BASED_ON_POLL && defined ZMQ_HAVE_AIX
  33. #include <poll.h>
  34. #endif
  35. #include "platform.hpp"
  36. #define __STDC_LIMIT_MACROS
  37. // This must be included before any windows headers are compiled.
  38. #if defined ZMQ_HAVE_WINDOWS
  39. #include "windows.hpp"
  40. #endif
  41. #if defined ZMQ_HAVE_OPENBSD
  42. #define ucred sockpeercred
  43. #endif
  44. // 0MQ definitions and exported functions
  45. #include "../include/zmq.h"
  46. // 0MQ DRAFT definitions and exported functions
  47. #include "zmq_draft.h"
  48. // TODO: expand pch implementation to non-windows builds.
  49. #ifdef _MSC_VER
  50. // standard C headers
  51. #include <assert.h>
  52. #include <ctype.h>
  53. #include <errno.h>
  54. #include <io.h>
  55. #include <ipexport.h>
  56. #include <iphlpapi.h>
  57. #include <limits.h>
  58. #include <mstcpip.h>
  59. #include <mswsock.h>
  60. #include <process.h>
  61. #include <rpc.h>
  62. #include <signal.h>
  63. #include <stdarg.h>
  64. #include <stddef.h>
  65. #include <stdio.h>
  66. #include <stdlib.h>
  67. #include <string.h>
  68. #include <sys/stat.h>
  69. #include <sys/types.h>
  70. #include <time.h>
  71. #include <winsock2.h>
  72. #include <ws2tcpip.h>
  73. // standard C++ headers
  74. #include <algorithm>
  75. #include <climits>
  76. #include <cmath>
  77. #include <cstddef>
  78. #include <cstdlib>
  79. #include <cstring>
  80. #include <deque>
  81. #include <limits>
  82. #include <map>
  83. #include <new>
  84. #include <set>
  85. #include <sstream>
  86. #include <string>
  87. #include <vector>
  88. #if _MSC_VER >= 1800
  89. #include <inttypes.h>
  90. #endif
  91. #if _MSC_VER >= 1700
  92. #include <atomic>
  93. #endif
  94. #if defined _WIN32_WCE
  95. #include <cmnintrin.h>
  96. #else
  97. #include <intrin.h>
  98. #endif
  99. #if defined HAVE_LIBGSSAPI_KRB5
  100. #include "err.hpp"
  101. #include "msg.hpp"
  102. #include "mechanism.hpp"
  103. #include "session_base.hpp"
  104. #include "gssapi_server.hpp"
  105. #include "wire.hpp"
  106. #include <gssapi/gssapi.h>
  107. #include <gssapi/gssapi_krb5.h>
  108. #endif
  109. #include "options.hpp"
  110. #endif // _MSC_VER
  111. #endif //ifndef __ZMQ_PRECOMPILED_HPP_INCLUDED__