mirror of
https://github.com/llvm-mirror/libcxx.git
synced 2025-10-25 04:56:13 +08:00
Check for _MSC_VER before defining _LIBCPP_MSVCRT
Some targets (e.g. Darwin) might have the Win32 API available, but they do not use MSVC CRT. Assume _LIBCPP_MSVCRT only when _MSC_VER is available and __MINGW32__ isn't defined. Differential Revision: https://reviews.llvm.org/D34588 rdar://problem/32628786 git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@308225 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -229,8 +229,9 @@
|
|||||||
# define _LIBCPP_SHORT_WCHAR 1
|
# define _LIBCPP_SHORT_WCHAR 1
|
||||||
// Both MinGW and native MSVC provide a "MSVC"-like enviroment
|
// Both MinGW and native MSVC provide a "MSVC"-like enviroment
|
||||||
# define _LIBCPP_MSVCRT_LIKE
|
# define _LIBCPP_MSVCRT_LIKE
|
||||||
// If mingw not explicitly detected, assume using MS C runtime only.
|
// If mingw not explicitly detected, assume using MS C runtime only if
|
||||||
# ifndef __MINGW32__
|
// a MS compatibility version is specified.
|
||||||
|
# if defined(_MSC_VER) && !defined(__MINGW32__)
|
||||||
# define _LIBCPP_MSVCRT // Using Microsoft's C Runtime library
|
# define _LIBCPP_MSVCRT // Using Microsoft's C Runtime library
|
||||||
# endif
|
# endif
|
||||||
# if (defined(_M_AMD64) || defined(__x86_64__)) || (defined(_M_ARM) || defined(__arm__))
|
# if (defined(_M_AMD64) || defined(__x86_64__)) || (defined(_M_ARM) || defined(__arm__))
|
||||||
|
|||||||
Reference in New Issue
Block a user