ios.h 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. /*
  2. Copyright Franz Detro 2014
  3. Copyright Rene Rivera 2015
  4. Distributed under the Boost Software License, Version 1.0.
  5. (See accompanying file LICENSE_1_0.txt or copy at
  6. http://www.boost.org/LICENSE_1_0.txt)
  7. */
  8. #ifndef BOOST_PREDEF_OS_IOS_H
  9. #define BOOST_PREDEF_OS_IOS_H
  10. #include <boost/predef/version_number.h>
  11. #include <boost/predef/make.h>
  12. /*`
  13. [heading `BOOST_OS_IOS`]
  14. [@http://en.wikipedia.org/wiki/iOS iOS] operating system.
  15. [table
  16. [[__predef_symbol__] [__predef_version__]]
  17. [[`__APPLE__`] [__predef_detection__]]
  18. [[`__MACH__`] [__predef_detection__]]
  19. [[`__ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__`] [__predef_detection__]]
  20. [[`__ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__`] [__ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__*1000]]
  21. ]
  22. */
  23. #define BOOST_OS_IOS BOOST_VERSION_NUMBER_NOT_AVAILABLE
  24. #if !defined(BOOST_PREDEF_DETAIL_OS_DETECTED) && ( \
  25. defined(__APPLE__) && defined(__MACH__) && \
  26. defined(__ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__) \
  27. )
  28. # undef BOOST_OS_IOS
  29. # define BOOST_OS_IOS (__ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__*1000)
  30. #endif
  31. #if BOOST_OS_IOS
  32. # define BOOST_OS_IOS_AVAILABLE
  33. # include <boost/predef/detail/os_detected.h>
  34. #endif
  35. #define BOOST_OS_IOS_NAME "iOS"
  36. #endif
  37. #include <boost/predef/detail/test.h>
  38. BOOST_PREDEF_DECLARE_TEST(BOOST_OS_IOS,BOOST_OS_IOS_NAME)