[Lldb-commits] [lldb] r253589 - Pass -fms-compatibility-version when building test inferiors.

Zachary Turner via lldb-commits lldb-commits at lists.llvm.org
Thu Nov 19 11:10:54 PST 2015


Author: zturner
Date: Thu Nov 19 13:10:54 2015
New Revision: 253589

URL: http://llvm.org/viewvc/llvm-project?rev=253589&view=rev
Log:
Pass -fms-compatibility-version when building test inferiors.

-fms-compatibility-version defaults to VS 2013.  When using
VS 2015, this will lead to compilation failures of the test
inferiors in the C++ standard library for language conformance
reasons.

The fix here is to simply pass -fms-compatibility-version=19.0 when
we detect that a VS 2015 compiler is present.  Even though we're
actually using clang to do the compilation, clang uses this same
detection algorithm to determine the location of the standard
library.  So this check is tantanmount to saying "If clang is going
to find MSVC 2015's standard library, then pass 19.0 for
-fms-compatibility-version.

Modified:
    lldb/trunk/packages/Python/lldbsuite/test/make/Makefile.rules

Modified: lldb/trunk/packages/Python/lldbsuite/test/make/Makefile.rules
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/packages/Python/lldbsuite/test/make/Makefile.rules?rev=253589&r1=253588&r2=253589&view=diff
==============================================================================
--- lldb/trunk/packages/Python/lldbsuite/test/make/Makefile.rules (original)
+++ lldb/trunk/packages/Python/lldbsuite/test/make/Makefile.rules Thu Nov 19 13:10:54 2015
@@ -253,6 +253,9 @@ ifeq "$(OS)" "Windows_NT"
 		# Clang for Windows doesn't support C++ Exceptions
 		CXXFLAGS += -fno-exceptions
 		CXXFLAGS += -D_HAS_EXCEPTIONS=0
+		ifeq "$(VisualStudioVersion)" "14.0"
+			CXXFLAGS += -fms-compatibility-version=19.0
+		endif
 		# The MSVC linker doesn't understand long section names
 		# generated by the clang compiler.
 		LDFLAGS += -fuse-ld=lld




More information about the lldb-commits mailing list