From 3a00a3e573ffd8eeebea4e62dd19c610cd598a18 Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Wed, 19 Apr 2006 18:45:29 +0000 Subject: [PATCH] Final piece to get relinked .o files buildable universal on Darwin. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27839 91177308-0d34-0410-b5e6-96231b3b80d8 --- Makefile.rules | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/Makefile.rules b/Makefile.rules index b9b0a2b5b72..462d0f8b33e 100644 --- a/Makefile.rules +++ b/Makefile.rules @@ -362,7 +362,11 @@ endif # If we are building a universal binary on Mac OS/X, pass extra options. This is # useful to people that want to link the LLVM libraries into their universal apps. ifdef UNIVERSAL - CompileCommonOpts += -arch i386 -arch ppc -isysroot /Developer/SDKs/MACOSX10.4u.sdk/ + CompileCommonOpts += \ + -arch i386 -arch ppc -isysroot /Developer/SDKs/MACOSX10.4u.sdk/ + Relink.Flags := -XCClinker -arch -XCClinker i386 -XCClinker -arch \ + -XCClinker ppc -XCClinker \ + -isysroot -XCClinker /Developer/SDKs/MACOSX10.4u.sdk/ DISABLE_AUTO_DEPENDENCIES=1 endif @@ -397,7 +401,7 @@ Preprocess.CXX= $(CXX) $(CPP.Flags) $(CompileCommonOpts) $(CXX.Flags) -E Link = $(LIBTOOL) $(LibTool.Flags) --mode=link $(CXX) $(CPP.Flags) \ $(CompileCommonOpts) $(LD.Flags) $(Strip) Relink = $(LIBTOOL) $(LibTool.Flags) --mode=link $(CXX) $(CPP.Flags) \ - $(CompileCommonOpts) + $(CompileCommonOpts) $(Relink.Flags) LTInstall = $(LIBTOOL) $(LibTool.Flags) --mode=install $(INSTALL) \ $(Install.Flags) ProgInstall = $(INSTALL) $(Install.StripFlag) -m 0755