diff options
author | RĂ©mi Verschelde <rverschelde@gmail.com> | 2020-02-24 10:35:17 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-02-24 10:35:17 +0100 |
commit | 9e4d11d10d3763d0ed2de156a5a4d52566157b2f (patch) | |
tree | 88524083c5b4be6404d285ff4341d468fc66da64 /SConstruct | |
parent | 128a55a597b0dfad4d7f5b94c64b37b0ce120899 (diff) | |
parent | c491232ae2e4788079525b75f449f45380a2120a (diff) |
Merge pull request #36503 from Redwan13/mac_os_build_fix
Scons: fixed build for vanilla clang in mac os x
Diffstat (limited to 'SConstruct')
-rw-r--r-- | SConstruct | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/SConstruct b/SConstruct index 08a87dbe6c..9c1644594f 100644 --- a/SConstruct +++ b/SConstruct @@ -353,10 +353,16 @@ if selected_platform in platform_list: elif methods.using_clang(env): # Apple LLVM versions differ from upstream LLVM version \o/, compare # in https://en.wikipedia.org/wiki/Xcode#Toolchain_versions - if (env["platform"] == "osx" or env["platform"] == "iphone") and major < 10: - print("Detected Apple Clang version older than 10, which does not fully " - "support C++17. Supported versions are Apple Clang 10 and later.") - sys.exit(255) + if env["platform"] == "osx" or env["platform"] == "iphone": + vanilla = methods.is_vanilla_clang(env) + if vanilla and major < 6: + print("Detected Clang version older than 6, which does not fully support " + "C++17. Supported versions are Clang 6 and later.") + sys.exit(255) + elif not vanilla and major < 10: + print("Detected Apple Clang version older than 10, which does not fully " + "support C++17. Supported versions are Apple Clang 10 and later.") + sys.exit(255) elif major < 6: print("Detected Clang version older than 6, which does not fully support " "C++17. Supported versions are Clang 6 and later.") |