PageRenderTime 243ms CodeModel.GetById 141ms app.highlight 1ms RepoModel.GetById 99ms app.codeStats 0ms

/mordor/version.h

http://github.com/mozy/mordor
C Header | 68 lines | 57 code | 9 blank | 2 comment | 1 complexity | 4decf16c54d31e82e27e13e8a403f0cf MD5 | raw file
 1#ifndef __MORDOR_VERSION_H__
 2#define __MORDOR_VERSION_H__
 3
 4// OS
 5#ifdef _WIN32
 6#   define WINDOWS
 7#else
 8#   define POSIX
 9#endif
10#ifdef __CYGWIN__
11#   define WINDOWS
12#   define CYGWIN
13#endif
14
15#if defined(linux) || defined(__linux__)
16#   define LINUX
17#endif
18
19#ifdef __APPLE__
20#   define OSX
21#   ifndef BSD
22#       define BSD
23#   endif
24#endif
25
26#ifdef __FreeBSD__
27#   define FREEBSD
28#   define BSD
29#endif
30
31#ifdef WINDOWS
32#define MORDOR_NATIVE(win32, posix) win32
33#else
34#define MORDOR_NATIVE(win32, posix) posix
35#endif
36
37// Architecture
38#ifdef _MSC_VER
39#   define MSVC
40#   ifdef _M_X64
41#       define X86_64
42#   elif defined(_M_IX86)
43#       define X86
44#   endif
45#endif
46
47#ifdef __GNUC__
48#   define GCC
49#   ifdef __x86_64
50#       define X86_64
51#   elif defined(__i386__)
52#       define X86
53#   elif defined(__ppc__)
54#       define PPC
55#   elif defined(__arm__)
56#       define ARM
57#   endif
58#endif
59
60#ifdef MSVC
61#   ifndef _DEBUG
62#       ifndef NDEBUG
63#           define NDEBUG
64#       endif
65#   endif
66#endif
67
68#endif