BaseDefines.h
// BaseDefines.h
//
// Author David Barrett-Lennard
// (C)opyright Cedanet Pty Ltd 2006
#pragma once
#ifndef Ceda_cxUtils_BaseDefines_H
#define Ceda_cxUtils_BaseDefines_H
/*
Notes on using preprocessor flags for platform dependent code
-------------------------------------------------------------
See: http://sourceforge.net/p/predef/wiki/Home/
Mac
---
Mac OS X iOS device iOS simulator
--------------------------------------------------------------
TARGET_OS_MAC 1 1 1
TARGET_OS_IPHONE 0 1 1
TARGET_OS_EMBEDDED 0 1 0
TARGET_IPHONE_SIMULATOR 0 0 1
Microsoft Windows
-----------------
Identification _WIN16 Defined for 16-bit environments 1
Identification _WIN32 Defined for both 32-bit and 64-bit environments 1
Identification _WIN64 Defined for 64-bit environments 1
Identification __WIN32__ Defined by Borland C++
Identification __TOS_WIN__ Defined by xlC
Identification __WINDOWS__ Defined by Watcom C/C++
Visual C++ _MSC_VER _MSC_FULL_VER
------------------------------------------
1.0 800
3.0 900
4.0 1000
4.2 1020
5.0 1100
6.0 1200
6.0 SP6 1200 12008804
7.0 1300 13009466
7.1 (2003) 1310 13103077
8.0 (2005) 1400 140050727
9.0 (2008) 1500 150021022
10.0 (2010) 1600 160040219
11.0 (2012) 1700 170050727
GCC
---
Identification __GNUC__
Version __GNUC__ Version
Version __GNUC_MINOR__ Revision
Version __GNUC_PATCHLEVEL__ Patch (introduced in version 3.0)
// Test for GCC > 3.2.0
#if __GNUC__ > 3 || \
(__GNUC__ == 3 && (__GNUC_MINOR__ > 2 || \
(__GNUC_MINOR__ == 2 && __GNUC_PATCHLEVEL__ > 0))
Test for Unix
-------------
#if defined(unix) || defined(__unix__) || defined(__unix)
Linux
-----
There are two major Linux-based operating systems: GNU/Linux and Android
__linux__
__gnu_linux__
__ANDROID__
*/
#if defined(__GNUC__)
#undef __stdcall
#define __stdcall
#endif
#endif // include guard