Improve message for appleclang

This commit is contained in:
Alexander Karatarakis 2018-03-30 14:46:22 -07:00
parent 0842b6c327
commit 35bbd4015a

View File

@ -4,8 +4,12 @@ project(vcpkg C CXX)
if(CMAKE_COMPILER_IS_GNUXX OR CMAKE_CXX_COMPILER_ID MATCHES "GNU")
set(GCC 1)
elseif(CMAKE_CXX_COMPILER_ID MATCHES "AppleClang")
if(CMAKE_CXX_COMPILER_VERSION VERSION_LESS_EQUAL 9.0.0)
message(FATAL_ERROR "Apple clang versions 9 and below do not have support for the C++ Filesystem TS. Please install gcc6 or newer from homebrew (brew install gcc6).")
if(NOT VCPKG_ALLOW_APPLE_CLANG)
message(FATAL_ERROR
"Building the vcpkg tool requires support for the C++ Filesystem TS.
Apple clang versions 9 and below do not have support for it.
Please install gcc6 or newer from homebrew (brew install gcc6).
If you would like to try anyway, set VCPKG_ALLOW_APPLE_CLANG.")
else()
set(CLANG 1)
endif()