COVISE Core
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros
common.h
Go to the documentation of this file.
1 /* This file is part of COVISE.
2 
3  You can use it under the terms of the GNU Lesser General Public License
4  version 2.1 or later, see lgpl-2.1.txt.
5 
6  * License: LGPL 2+ */
7 
8 #ifndef COMMON_INCLUDE_FILES_AND_DEFINES_FOR_COVISE_AND_YAC
9 #define COMMON_INCLUDE_FILES_AND_DEFINES_FOR_COVISE_AND_YAC
10 
11 #if defined(__linux__) && !defined(_POSIX_SOURCE)
12 #define _POSIX_SOURCE
13 #endif
14 
15 #if defined(__APPLE__) && defined(__LITTLE_ENDIAN__)
16 #ifndef BYTESWAP
17 #define BYTESWAP
18 #endif
19 #endif
20 
21 #ifdef _WIN32
22 
23 #ifndef _WIN32_WINNT
24 #define _WIN32_WINNT 0x501 // This specifies WinXP or later - it is needed to access rawmouse from the user32.dll
25 #endif
26 
27 #if (_MSC_VER > 1310) && !(defined(MIDL_PASS) || defined(RC_INVOKED))
28 #ifndef _WIN32_WCE
29 #define POINTER_64 __ptr64
30 #endif
31 #else
32 #define POINTER_64
33 #endif
34 /* windows.h would include winsock.h, so be faster */
35 #include <winsock2.h>
36 #include <windows.h>
37 #ifndef _WIN32_WCE
38 #include <process.h>
39 #endif
40 #else
41 #include <unistd.h>
42 #endif
43 #if !defined(_USE_MATH_DEFINES) && !defined(__MINGW32__)
44 #define _USE_MATH_DEFINES
45 #endif
46 
47 #ifndef _WIN32_WCE
48 #include <sysdep/net.h>
49 #include "coExport.h"
50 #include <sys/types.h>
51 #endif
52 
53 #if defined __cplusplus
54 #include <cassert>
55 #include <cctype>
56 #include <cerrno>
57 #include <cfloat>
58 #include <climits>
59 #include <cmath>
60 #include <csignal>
61 #include <cstdarg>
62 #include <cstddef>
63 #include <cstdio>
64 #include <cstring>
65 #include <ctime>
66 #else
67 #include <assert.h>
68 #include <ctype.h>
69 #ifndef _WIN32_WCE
70 #include <errno.h>
71 #include <signal.h>
72 #endif
73 #include <float.h>
74 #include <limits.h>
75 #include <math.h>
76 #include <stdarg.h>
77 #include <stddef.h>
78 #include <stdio.h>
79 #include <stdlib.h>
80 #include <string.h>
81 #include <time.h>
82 #endif
83 
84 #ifdef _WIN32
85 #ifndef _WIN32_WCE
86 #include <io.h>
87 #endif
88 #else
89 #include <unistd.h>
90 #ifndef __hpux
91 #include <sys/select.h>
92 #endif
93 #if defined(__sgi) || defined(__hpux) || defined(_SX) || defined(__linux__) || defined(__APPLE__)
94 #include <fcntl.h>
95 #endif
96 #endif
97 
98 #ifdef __cplusplus
99 
100 #include <iostream>
101 #include <sstream>
102 #include <fstream>
103 #include <iomanip>
104 
105 using std::cout;
106 using std::cerr;
107 using std::cin;
108 using std::endl;
109 using std::flush;
110 using std::ostream;
111 using std::ofstream;
112 using std::fstream;
113 using std::istream;
114 using std::ios;
115 using std::ifstream;
116 using std::istringstream;
117 using std::ostringstream;
118 using std::stringstream;
119 
120 #include <set>
121 using std::set;
122 
123 #include <map>
124 using std::map;
125 using std::multimap;
126 
127 #include <list>
128 using std::list;
129 
130 #include <vector>
131 using std::vector;
132 using std::allocator;
133 
134 #include <string>
135 using std::string;
136 
137 #include <memory>
138 using std::pair;
139 
140 #include <stack>
141 using std::stack;
142 
143 #include <algorithm>
144 using std::find;
145 
146 #endif /* __cplusplus */
147 
148 #if defined(__linux__) || defined(__MINGW32__)
149 #include <stdint.h>
150 #endif
151 
152 #ifdef _MSC_VER
153 typedef unsigned __int16 uint16_t;
154 typedef unsigned __int32 uint32_t;
155 typedef unsigned __int64 uint64_t;
156 typedef __int16 int16_t;
157 typedef __int32 int32_t;
158 typedef __int64 int64_t;
159 /* #define memcpy(a,b,c) memcpy_s(a,c,b,c) */
160 #endif
161 #endif /* COVISE_H */
GLsizei const GLchar *const * string
Definition: khronos-glext.h:6750