[Lldb-commits] [lldb] r235056 - Fix OS default in Makefile.rules for Windows. http://reviews.llvm.org/D9043
Adrian McCarthy
amccarth at google.com
Wed Apr 15 16:38:23 PDT 2015
Author: amccarth
Date: Wed Apr 15 18:38:23 2015
New Revision: 235056
URL: http://llvm.org/viewvc/llvm-project?rev=235056&view=rev
Log:
Fix OS default in Makefile.rules for Windows. http://reviews.llvm.org/D9043
Modified:
lldb/trunk/test/make/Makefile.rules
Modified: lldb/trunk/test/make/Makefile.rules
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/test/make/Makefile.rules?rev=235056&r1=235055&r2=235056&view=diff
==============================================================================
--- lldb/trunk/test/make/Makefile.rules (original)
+++ lldb/trunk/test/make/Makefile.rules Wed Apr 15 18:38:23 2015
@@ -30,8 +30,22 @@ THIS_FILE_DIR := $(shell dirname $(realp
LLDB_BASE_DIR := $(THIS_FILE_DIR)../../
#----------------------------------------------------------------------
-# If ARCH is not defined, default to x86_64.
# If OS is not defined, use 'uname -s' to determine the OS name.
+#
+# uname on Windows gives "windows32", but most environments standardize
+# on "Windows_NT", so we'll make it consistent here. When running
+# tests from Visual Studio, the environment variable isn't inherited
+# all the way down to the process spawned for make.
+#----------------------------------------------------------------------
+ifeq "$(OS)" ""
+ OS = $(shell uname -s)
+endif
+ifeq "$(OS)" "windows32"
+ OS = Windows_NT
+endif
+
+#----------------------------------------------------------------------
+# If ARCH is not defined, default to x86_64.
#----------------------------------------------------------------------
ifeq "$(ARCH)" ""
ifeq "$(OS)" "Windows_NT"
@@ -41,10 +55,6 @@ else
endif
endif
-ifeq "$(OS)" ""
- OS = $(shell uname -s)
-endif
-
#----------------------------------------------------------------------
# CC defaults to clang.
#
More information about the lldb-commits
mailing list