diff options
Diffstat (limited to 'libcxx/CMakeLists.txt')
-rw-r--r-- | libcxx/CMakeLists.txt | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/libcxx/CMakeLists.txt b/libcxx/CMakeLists.txt index c87e3562c3a..fb866e1ebc9 100644 --- a/libcxx/CMakeLists.txt +++ b/libcxx/CMakeLists.txt @@ -53,6 +53,7 @@ MACRO_ENSURE_OUT_OF_SOURCE_BUILD( if (MSVC) set(LIBCXX_TARGETING_MSVC ON) + message(STATUS "Configuring for MSVC") else() set(LIBCXX_TARGETING_MSVC OFF) endif() @@ -504,8 +505,10 @@ if (LIBCXX_HAS_MUSL_LIBC) set(LIBCXX_STANDARD_VER c++14 CACHE INTERNAL "internal option to change build dialect") endif() add_compile_flags_if_supported(-std=${LIBCXX_STANDARD_VER}) +add_compile_flags_if_supported("/std:${LIBCXX_STANDARD_VER}") mangle_name("LIBCXX_SUPPORTS_STD_EQ_${LIBCXX_STANDARD_VER}_FLAG" SUPPORTS_DIALECT_NAME) -if(NOT ${SUPPORTS_DIALECT_NAME}) +mangle_name("LIBCXX_SUPPORTS_STD_COLON_${LIBCXX_STANDARD_VER}_FLAG" SUPPORTS_DIALECT_NAME_MSVC) +if(NOT ${SUPPORTS_DIALECT_NAME} AND NOT ${SUPPORTS_DIALECT_NAME_MSVC}) if(NOT "${CMAKE_CXX_COMPILER_ID}" STREQUAL "MSVC" AND NOT "${CMAKE_CXX_SIMULATE_ID}" STREQUAL "MSVC") message(FATAL_ERROR "C++11 or greater is required but the compiler does not support ${LIBCXX_STANDARD_VER}") endif() |