Go to the documentation of this file.
36 #define OGRE_PLATFORM_WIN32 1
37 #define OGRE_PLATFORM_LINUX 2
38 #define OGRE_PLATFORM_APPLE 3
39 #define OGRE_PLATFORM_APPLE_IOS 4
40 #define OGRE_PLATFORM_ANDROID 5
41 #define OGRE_PLATFORM_NACL 6
42 #define OGRE_PLATFORM_WINRT 7
44 #define OGRE_COMPILER_MSVC 1
45 #define OGRE_COMPILER_GNUC 2
46 #define OGRE_COMPILER_BORL 3
47 #define OGRE_COMPILER_WINSCW 4
48 #define OGRE_COMPILER_GCCE 5
49 #define OGRE_COMPILER_CLANG 6
51 #define OGRE_ENDIAN_LITTLE 1
52 #define OGRE_ENDIAN_BIG 2
54 #define OGRE_ARCHITECTURE_32 1
55 #define OGRE_ARCHITECTURE_64 2
59 #if defined( __GCCE__ )
60 # define OGRE_COMPILER OGRE_COMPILER_GCCE
61 # define OGRE_COMP_VER _MSC_VER
63 #elif defined( __WINSCW__ )
64 # define OGRE_COMPILER OGRE_COMPILER_WINSCW
65 # define OGRE_COMP_VER _MSC_VER
66 #elif defined( _MSC_VER )
67 # define OGRE_COMPILER OGRE_COMPILER_MSVC
68 # define OGRE_COMP_VER _MSC_VER
69 #elif defined( __clang__ )
70 # define OGRE_COMPILER OGRE_COMPILER_CLANG
71 # define OGRE_COMP_VER (((__clang_major__)*100) + \
72 (__clang_minor__*10) + \
74 #elif defined( __GNUC__ )
75 # define OGRE_COMPILER OGRE_COMPILER_GNUC
76 # define OGRE_COMP_VER (((__GNUC__)*100) + \
77 (__GNUC_MINOR__*10) + \
79 #elif defined( __BORLANDC__ )
80 # define OGRE_COMPILER OGRE_COMPILER_BORL
81 # define OGRE_COMP_VER __BCPLUSPLUS__
82 # define __FUNCTION__ __FUNC__
84 # pragma error "No known compiler. Abort! Abort!"
89 #if OGRE_COMPILER == OGRE_COMPILER_MSVC
90 # if OGRE_COMP_VER >= 1200
91 # define FORCEINLINE __forceinline
93 #elif defined(__MINGW32__)
94 # if !defined(FORCEINLINE)
95 # define FORCEINLINE __inline
98 # define FORCEINLINE __inline
102 #if defined( __WIN32__ ) || defined( _WIN32 )
103 # if defined(WINAPI_FAMILY)
104 # define __OGRE_HAVE_DIRECTXMATH 1
105 # include <winapifamily.h>
106 # if WINAPI_FAMILY == WINAPI_FAMILY_APP|| WINAPI_FAMILY == WINAPI_FAMILY_PHONE_APP
107 # define DESKTOP_APP 1
109 # define OGRE_PLATFORM OGRE_PLATFORM_WINRT
110 # define _CRT_SECURE_NO_WARNINGS
111 # define _SCL_SECURE_NO_WARNINGS
112 # if WINAPI_FAMILY == WINAPI_FAMILY_APP
113 # define OGRE_WINRT_TARGET_TYPE DESKTOP_APP
115 # if WINAPI_FAMILY == WINAPI_FAMILY_PHONE_APP
116 # define OGRE_WINRT_TARGET_TYPE PHONE
119 # define OGRE_PLATFORM OGRE_PLATFORM_WIN32
122 # define OGRE_PLATFORM OGRE_PLATFORM_WIN32
124 #elif defined(__FLASHCC__)
125 # define OGRE_PLATFORM OGRE_PLATFORM_FLASHCC
126 #elif defined( __APPLE_CC__)
129 # if __ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__ >= 60000 || __IPHONE_OS_VERSION_MIN_REQUIRED >= 60000
130 # define OGRE_PLATFORM OGRE_PLATFORM_APPLE_IOS
132 # define OGRE_PLATFORM OGRE_PLATFORM_APPLE
134 #elif defined(__ANDROID__)
135 # define OGRE_PLATFORM OGRE_PLATFORM_ANDROID
136 #elif defined( __native_client__ )
137 # define OGRE_PLATFORM OGRE_PLATFORM_NACL
138 # ifndef OGRE_STATIC_LIB
139 # error OGRE must be built as static for NaCl (OGRE_STATIC=true in CMake)
141 # ifdef OGRE_BUILD_RENDERSYSTEM_D3D9
142 # error D3D9 is not supported on NaCl (OGRE_BUILD_RENDERSYSTEM_D3D9 false in CMake)
144 # ifdef OGRE_BUILD_RENDERSYSTEM_GL
145 # error OpenGL is not supported on NaCl (OGRE_BUILD_RENDERSYSTEM_GL=false in CMake)
147 # ifndef OGRE_BUILD_RENDERSYSTEM_GLES2
148 # error GLES2 render system is required for NaCl (OGRE_BUILD_RENDERSYSTEM_GLES2=false in CMake)
151 # define OGRE_PLATFORM OGRE_PLATFORM_LINUX
155 #if defined(__x86_64__) || defined(_M_X64) || defined(__powerpc64__) || defined(__alpha__) || defined(__ia64__) || defined(__s390__) || defined(__s390x__)
156 # define OGRE_ARCH_TYPE OGRE_ARCHITECTURE_64
158 # define OGRE_ARCH_TYPE OGRE_ARCHITECTURE_32
164 #define OGRE_QUOTE_INPLACE(x) # x
165 #define OGRE_QUOTE(x) OGRE_QUOTE_INPLACE(x)
166 #define OGRE_WARN( x ) message( __FILE__ "(" QUOTE( __LINE__ ) ") : " x "\n" )
169 #if OGRE_COMPILER == OGRE_COMPILER_MSVC
170 # define OGRE_DEPRECATED(func) __declspec(deprecated) func
171 #elif OGRE_COMPILER == OGRE_COMPILER_GNUC || OGRE_COMPILER == OGRE_COMPILER_CLANG
172 # define OGRE_DEPRECATED(func) func __attribute__ ((deprecated))
174 # pragma message("WARNING: You need to implement OGRE_DEPRECATED for this compiler")
175 # define OGRE_DEPRECATED(func) func
180 #if OGRE_PLATFORM == OGRE_PLATFORM_WIN32 || OGRE_PLATFORM == OGRE_PLATFORM_WINRT
184 # if defined( OGRE_STATIC_LIB )
187 # define _OgrePrivate
189 # if defined( OGRE_NONCLIENT_BUILD )
190 # define _OgreExport __declspec( dllexport )
192 # if defined( __MINGW32__ )
195 # define _OgreExport __declspec( dllimport )
198 # define _OgrePrivate
202 # if defined(_DEBUG) || defined(DEBUG)
203 # define OGRE_DEBUG_MODE 1
205 # define OGRE_DEBUG_MODE 0
212 #if defined(__MINGW32__)
213 # if OGRE_COMP_VER < 400
214 # if !defined(_STLPORT_VERSION)
216 # if defined(__MINGW32_TOOLBOX_UNICODE__) || OGRE_COMP_VER > 345
217 # define OGRE_UNICODE_SUPPORT 1
219 # define OGRE_UNICODE_SUPPORT 0
222 # define OGRE_UNICODE_SUPPORT 1
225 # define OGRE_UNICODE_SUPPORT 1
228 # define OGRE_UNICODE_SUPPORT 1
231 #endif // OGRE_PLATFORM == OGRE_PLATFORM_WIN32 || OGRE_PLATFORM == OGRE_PLATFORM_WINRT
235 #if OGRE_PLATFORM == OGRE_PLATFORM_LINUX || OGRE_PLATFORM == OGRE_PLATFORM_APPLE || OGRE_PLATFORM == OGRE_PLATFORM_APPLE_IOS || \
236 OGRE_PLATFORM == OGRE_PLATFORM_ANDROID || OGRE_PLATFORM == OGRE_PLATFORM_NACL || OGRE_PLATFORM == OGRE_PLATFORM_FLASHCC
239 # if defined( OGRE_GCC_VISIBILITY )
240 # define _OgreExport __attribute__ ((visibility("default")))
241 # define _OgrePrivate __attribute__ ((visibility("hidden")))
244 # define _OgrePrivate
248 # define stricmp strcasecmp
251 # define OGRE_DEBUG_MODE 1
253 # define OGRE_DEBUG_MODE 0
258 #define OGRE_UNICODE_SUPPORT 1
264 #if OGRE_PLATFORM == OGRE_PLATFORM_ANDROID
265 # ifdef OGRE_UNICODE_SUPPORT
266 # undef OGRE_UNICODE_SUPPORT
268 # define OGRE_UNICODE_SUPPORT 1
269 # define CLOCKS_PER_SEC 1000
271 # define stricmp strcasecmp
273 # define OGRE_DEBUG_MODE 1
275 # define OGRE_DEBUG_MODE 0
281 #if OGRE_PLATFORM == OGRE_PLATFORM_FLASHCC
282 # ifdef OGRE_UNICODE_SUPPORT
283 # undef OGRE_UNICODE_SUPPORT
285 # define OGRE_UNICODE_SUPPORT 0
287 # define OGRE_DEBUG_MODE 1
289 # define OGRE_DEBUG_MODE 0
296 #ifdef OGRE_CONFIG_BIG_ENDIAN
297 # define OGRE_ENDIAN OGRE_ENDIAN_BIG
299 # define OGRE_ENDIAN OGRE_ENDIAN_LITTLE
304 #if OGRE_PLATFORM == OGRE_PLATFORM_ANDROID
306 # define OGRE_DEFAULT_LOCALE ""
307 #elif OGRE_PLATFORM == OGRE_PLATFORM_APPLE_IOS
308 # define OGRE_DEFAULT_LOCALE "C"
310 # if OGRE_COMPILER == OGRE_COMPILER_MSVC
311 # if _MSC_VER >= 1700
312 # define OGRE_DEFAULT_LOCALE "en-GB"
315 # define OGRE_DEFAULT_LOCALE "uk"
317 # elif OGRE_COMPILER == OGRE_COMPILER_GCCE
319 # define OGRE_DEFAULT_LOCALE "en_GB.UTF8"
321 # if OGRE_NO_LIBCPP_SUPPORT == 0
322 # define OGRE_DEFAULT_LOCALE "en_GB.UTF-8"
324 # define OGRE_DEFAULT_LOCALE "C"
333 # define OGRE_BUILD_SUFFIX "_d"
335 # define OGRE_BUILD_SUFFIX ""
346 #if OGRE_COMPILER == OGRE_COMPILER_MSVC
347 typedef unsigned __int64
uint64;
348 typedef __int64
int64;
355 #if OGRE_COMPILER == OGRE_COMPILER_MSVC
356 # define _CRT_SECURE_NO_WARNINGS
357 # define _SCL_SECURE_NO_WARNINGS
360 # pragma warning (disable : 4786)
363 # pragma warning (disable : 4503)
366 # pragma warning (disable : 4251)
370 # pragma warning (disable : 4275)
374 # pragma warning( disable : 4290 )
378 # pragma warning( disable: 4661)
384 # pragma warning( disable: 4996)
387 # pragma warning (disable : 201)
390 # pragma warning (disable : 4100)
393 # pragma warning (disable : 4345)
Copyright © 2012 Torus Knot Software Ltd

This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.
Last modified Wed Oct 16 2013 14:35:43