1 | /* |
2 | Copyright Rene Rivera 2008-2015 |
3 | Distributed under the Boost Software License, Version 1.0. |
4 | (See accompanying file LICENSE_1_0.txt or copy at |
5 | http://www.boost.org/LICENSE_1_0.txt) |
6 | */ |
7 | |
8 | #ifndef BOOST_PREDEF_PLAT_MINGW_H |
9 | #define BOOST_PREDEF_PLAT_MINGW_H |
10 | |
11 | #include <boost/predef/version_number.h> |
12 | #include <boost/predef/make.h> |
13 | |
14 | /*` |
15 | [heading `BOOST_PLAT_MINGW`] |
16 | |
17 | [@http://en.wikipedia.org/wiki/MinGW MinGW] platform. |
18 | Version number available as major, minor, and patch. |
19 | |
20 | [table |
21 | [[__predef_symbol__] [__predef_version__]] |
22 | |
23 | [[`__MINGW32__`] [__predef_detection__]] |
24 | [[`__MINGW64__`] [__predef_detection__]] |
25 | |
26 | [[`__MINGW64_VERSION_MAJOR`, `__MINGW64_VERSION_MINOR`] [V.R.0]] |
27 | [[`__MINGW32_VERSION_MAJOR`, `__MINGW32_VERSION_MINOR`] [V.R.0]] |
28 | ] |
29 | */ |
30 | |
31 | #define BOOST_PLAT_MINGW BOOST_VERSION_NUMBER_NOT_AVAILABLE |
32 | |
33 | #if defined(__MINGW32__) || defined(__MINGW64__) |
34 | # include <_mingw.h> |
35 | # if !defined(BOOST_PLAT_MINGW_DETECTION) && (defined(__MINGW64_VERSION_MAJOR) && defined(__MINGW64_VERSION_MINOR)) |
36 | # define BOOST_PLAT_MINGW_DETECTION \ |
37 | BOOST_VERSION_NUMBER(__MINGW64_VERSION_MAJOR,__MINGW64_VERSION_MINOR,0) |
38 | # endif |
39 | # if !defined(BOOST_PLAT_MINGW_DETECTION) && (defined(__MINGW32_VERSION_MAJOR) && defined(__MINGW32_VERSION_MINOR)) |
40 | # define BOOST_PLAT_MINGW_DETECTION \ |
41 | BOOST_VERSION_NUMBER(__MINGW32_MAJOR_VERSION,__MINGW32_MINOR_VERSION,0) |
42 | # endif |
43 | # if !defined(BOOST_PLAT_MINGW_DETECTION) |
44 | # define BOOST_PLAT_MINGW_DETECTION BOOST_VERSION_NUMBER_AVAILABLE |
45 | # endif |
46 | #endif |
47 | |
48 | #ifdef BOOST_PLAT_MINGW_DETECTION |
49 | # define BOOST_PLAT_MINGW_AVAILABLE |
50 | # if defined(BOOST_PREDEF_DETAIL_PLAT_DETECTED) |
51 | # define BOOST_PLAT_MINGW_EMULATED BOOST_PLAT_MINGW_DETECTION |
52 | # else |
53 | # undef BOOST_PLAT_MINGW |
54 | # define BOOST_PLAT_MINGW BOOST_PLAT_MINGW_DETECTION |
55 | # endif |
56 | # include <boost/predef/detail/platform_detected.h> |
57 | #endif |
58 | |
59 | #define BOOST_PLAT_MINGW_NAME "MinGW" |
60 | |
61 | #endif |
62 | |
63 | #include <boost/predef/detail/test.h> |
64 | BOOST_PREDEF_DECLARE_TEST(BOOST_PLAT_MINGW,BOOST_PLAT_MINGW_NAME) |
65 | |
66 | #ifdef BOOST_PLAT_MINGW_EMULATED |
67 | #include <boost/predef/detail/test.h> |
68 | BOOST_PREDEF_DECLARE_TEST(BOOST_PLAT_MINGW_EMULATED,BOOST_PLAT_MINGW_NAME) |
69 | #endif |
70 | |