Fix PR3743 - -mmacosx-version-min inappropriate for Mac OS X 10.4.11,

by stripping off any versions past the "10.4".

llvm-svn: 66392
This commit is contained in:
Chris Lattner 2009-03-09 04:45:03 +00:00
parent 6772621acf
commit 3b935fbcf2
1 changed files with 3 additions and 0 deletions

View File

@ -467,6 +467,9 @@ endif
ifeq ($(OS),Darwin)
DARWIN_VERSION := `sw_vers -productVersion`
# Strip a number like 10.4.7 to 10.4
DARWIN_VERSION := $(shell echo $(DARWIN_VERSION)| sed -E 's/(10.[0-9]).*/\1/')
SharedLinkOptions=-Wl,-flat_namespace -Wl,-undefined -Wl,suppress -bundle \
-mmacosx-version-min=$(DARWIN_VERSION)
CompileCommonOpts += -mmacosx-version-min=$(DARWIN_VERSION)