[Lldb-commits] [lldb] r238871 - Fixed the logic to determine the TRIPLE_VERSION correctly when it isn't specified.

Greg Clayton gclayton at apple.com
Tue Jun 2 14:42:31 PDT 2015


Author: gclayton
Date: Tue Jun  2 16:42:31 2015
New Revision: 238871

URL: http://llvm.org/viewvc/llvm-project?rev=238871&view=rev
Log:
Fixed the logic to determine the TRIPLE_VERSION correctly when it isn't specified.


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=238871&r1=238870&r2=238871&view=diff
==============================================================================
--- lldb/trunk/test/make/Makefile.rules (original)
+++ lldb/trunk/test/make/Makefile.rules Tue Jun  2 16:42:31 2015
@@ -43,22 +43,24 @@ ifneq "$(TRIPLE)" ""
 	triple_os_and_version =$(shell echo $(word 3, $(triple_space)) | sed -e 's/\(.*\)\([0-9]\.[0-9]\).*/\1 \2/')
 	TRIPLE_OS =$(word 1, $(triple_os_and_version))
 	TRIPLE_VERSION =$(word 2, $(triple_os_and_version))
-	ifeq "$(TRIPLE_VERSION)" ""
-		TRIPLE_VERSION =$(shell echo $(sdk_basename) | sed -e 's/.*\([0-9]\.[0-9]\).*/\1/')
-	endif
 	ifeq "$(TRIPLE_VENDOR)" "apple"
 		ifeq "$(TRIPLE_OS)" "ios"
 		    ifeq "$(SDKROOT)" ""
 				# Set SDKROOT if it wasn't set
 				ifneq (,$(findstring arm,$(ARCH)))
 					SDKROOT = $(shell xcrun --sdk iphoneos --show-sdk-path)
+					ifeq "$(TRIPLE_VERSION)" ""
+						TRIPLE_VERSION =$(shell echo $(notdir $(SDKROOT)) | sed -e 's/.*\([0-9]\.[0-9]\).*/\1/')
+					endif
 					TRIPLE_CFLAGS :=-mios-version-min=$(TRIPLE_VERSION) -isysroot "$(SDKROOT)"
 				else
 					SDKROOT = $(shell xcrun --sdk iphonesimulator --show-sdk-path)
+					ifeq "$(TRIPLE_VERSION)" ""
+						TRIPLE_VERSION =$(shell echo $(notdir $(SDKROOT)) | sed -e 's/.*\([0-9]\.[0-9]\).*/\1/')
+					endif
 					TRIPLE_CFLAGS :=-mios-simulator-version-min=$(TRIPLE_VERSION) -isysroot "$(SDKROOT)"
 				endif
 			endif
-			sdk_basename = $(notdir $(SDKROOT))
 		endif
 	endif
 endif





More information about the lldb-commits mailing list