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