[cfe-commits] r125328 - /cfe/trunk/runtime/Makefile

Daniel Dunbar daniel at zuster.org
Thu Feb 10 17:29:49 PST 2011


Author: ddunbar
Date: Thu Feb 10 19:29:49 2011
New Revision: 125328

URL: http://llvm.org/viewvc/llvm-project?rev=125328&view=rev
Log:
build/compiler-rt: Fake Clang into using the right assembler to build the ARM
bits for the runtime libraries.

Modified:
    cfe/trunk/runtime/Makefile

Modified: cfe/trunk/runtime/Makefile
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/runtime/Makefile?rev=125328&r1=125327&r2=125328&view=diff
==============================================================================
--- cfe/trunk/runtime/Makefile (original)
+++ cfe/trunk/runtime/Makefile Thu Feb 10 19:29:49 2011
@@ -28,6 +28,9 @@
 # Expect compiler-rt to be in llvm/projects/compiler-rt
 COMPILERRT_SRC_ROOT := $(LLVM_SRC_ROOT)/projects/compiler-rt
 
+# Additional flags to pass to Clang.
+CLANG_CCFLAGS := -no-integrated-as
+
 ifneq ($(CLANG_NO_RUNTIME),1)
 ifeq ($(shell test -d $(COMPILERRT_SRC_ROOT) && echo OK),OK)
 
@@ -40,6 +43,13 @@
 ifeq ($(OS),Darwin)
 RuntimeDirs += darwin
 RuntimeLibrary.darwin.Configs = eprintf 10.4 armv6 cc_kext
+
+# On Darwin, fake Clang into using the iOS assembler (since compiler-rt wants to
+# build ARM bits).
+ifeq ($(OS),Darwin)
+CLANG_CCFLAGS += -ccc-install-dir \
+	/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/
+endif
 endif
 
 # Rule to build the compiler-rt libraries we need.
@@ -50,7 +60,7 @@
 	$(Verb) $(MAKE) -C $(COMPILERRT_SRC_ROOT) \
 	  ProjSrcRoot=$(COMPILERRT_SRC_ROOT) \
 	  ProjObjRoot=$(PROJ_OBJ_DIR) \
-	  CC="$(ToolDir)/clang -no-integrated-as" \
+	  CC="$(ToolDir)/clang $(CLANG_CCFLAGS)" \
 	  $(RuntimeDirs:%=clang_%)
 .PHONY: BuildRuntimeLibraries
 CleanRuntimeLibraries:





More information about the cfe-commits mailing list