1 //===------------------------ apple_availability.h ------------------------===// 2 // 3 // The LLVM Compiler Infrastructure 4 // 5 // This file is dual licensed under the MIT and the University of Illinois Open 6 // Source Licenses. See LICENSE.TXT for details. 7 // 8 //===----------------------------------------------------------------------===// 9 #ifndef _LIBCPP_SRC_INCLUDE_APPLE_AVAILABILITY_H 10 #define _LIBCPP_SRC_INCLUDE_APPLE_AVAILABILITY_H 11 12 #if defined(__APPLE__) 13 14 #if defined(__ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__) 15 #if __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ >= 101300 16 #define _LIBCPP_USE_UTIMENSAT 17 #endif 18 #elif defined(__ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__) 19 #if __ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__ >= 110000 20 #define _LIBCPP_USE_UTIMENSAT 21 #endif 22 #elif defined(__ENVIRONMENT_TV_OS_VERSION_MIN_REQUIRED__) 23 #if __ENVIRONMENT_TV_OS_VERSION_MIN_REQUIRED__ >= 110000 24 #define _LIBCPP_USE_UTIMENSAT 25 #endif 26 #elif defined(__ENVIRONMENT_WATCH_OS_VERSION_MIN_REQUIRED__) 27 #if __ENVIRONMENT_WATCH_OS_VERSION_MIN_REQUIRED__ >= 40000 28 #define _LIBCPP_USE_UTIMENSAT 29 #endif 30 #endif // __ENVIRONMENT_.*_VERSION_MIN_REQUIRED__ 31 32 #if defined(__ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__) 33 #if __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ >= 101200 34 #define _LIBCPP_USE_CLOCK_GETTIME 35 #endif 36 #elif defined(__ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__) 37 #if __ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__ >= 100000 38 #define _LIBCPP_USE_CLOCK_GETTIME 39 #endif 40 #elif defined(__ENVIRONMENT_TV_OS_VERSION_MIN_REQUIRED__) 41 #if __ENVIRONMENT_TV_OS_VERSION_MIN_REQUIRED__ >= 100000 42 #define _LIBCPP_USE_CLOCK_GETTIME 43 #endif 44 #elif defined(__ENVIRONMENT_WATCH_OS_VERSION_MIN_REQUIRED__) 45 #if __ENVIRONMENT_WATCH_OS_VERSION_MIN_REQUIRED__ >= 30000 46 #define _LIBCPP_USE_CLOCK_GETTIME 47 #endif 48 #endif // __ENVIRONMENT_.*_VERSION_MIN_REQUIRED__ 49 50 #endif // __APPLE__ 51 52 #endif // _LIBCPP_SRC_INCLUDE_APPLE_AVAILABILITY_H 53