Make built bytecode libraries depend on gccas/gccld as appropriate. This
authorChris Lattner <sabre@nondot.org>
Mon, 29 Nov 2004 19:47:58 +0000 (19:47 +0000)
committerChris Lattner <sabre@nondot.org>
Mon, 29 Nov 2004 19:47:58 +0000 (19:47 +0000)
should fix the stale runtime libraries problem.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18361 91177308-0d34-0410-b5e6-96231b3b80d8

Makefile.rules

index 2a49a4623e6877560fb24c8abeaa3c464cdc02c0..9897fc87846f001bd1d15b7a16b22de0253edcfd 100644 (file)
@@ -201,6 +201,9 @@ endif
 ifndef TBLGEN
 TBLGEN   := $(LLVMToolDir)/tblgen$(EXEEXT)
 endif
+ifndef GCCAS
+GCCAS    := $(LLVMToolDir)/gccas$(EXEEXT)
+endif
 ifndef GCCLD
 GCCLD    := $(LLVMToolDir)/gccld$(EXEEXT)
 endif
@@ -520,7 +523,7 @@ endif
 
 all-local:: $(LibName.BC)
 
-$(LibName.BC): $(BUILT_SOURCES) $(ObjectsBC) $(LibDir)/.dir
+$(LibName.BC): $(BUILT_SOURCES) $(ObjectsBC) $(LibDir)/.dir $(GCCLD)
        $(Echo) Linking $(BuildMode) Bytecode Library $(notdir $@)
        $(Verb) $(BCLinkLib) -o $@ $(ObjectsBC)
 
@@ -782,13 +785,13 @@ endif
 #---------------------------------------------------------
 # Create .bc files in the ObjDir directory from .cpp and .c files...
 #---------------------------------------------------------
-$(ObjDir)/%.bc: %.cpp $(ObjDir)/.dir
+$(ObjDir)/%.bc: %.cpp $(ObjDir)/.dir $(GCCAS)
        $(Echo) "Compiling $*.cpp for $(BuildMode) build (bytecode)"
        $(Verb) if $(BCCompile.CXX) -MD -MT $@ -MP -MF "$(ObjDir)/$*.BCCXXd" $< -o $@ ; \
        then $(MV) -f "$(ObjDir)/$*.BCCXXd" "$(ObjDir)/$*.d"; \
        else $(RM) -f "$(ObjDir)/$*.BCCXXd"; exit 1; fi
 
-$(ObjDir)/%.bc: %.c $(ObjDir)/.dir
+$(ObjDir)/%.bc: %.c $(ObjDir)/.dir $(GCCAS)
        $(Echo) "Compiling $*.c for $(BuildMode) build (bytecode)"
        $(Verb) if $(BCCompile.C) -MD -MT $@ -MP -MF "$(ObjDir)/$*.BCCd" $< -o $@ ; \
        then $(MV) -f "$(ObjDir)/$*.BCCd" "$(ObjDir)/$*.d"; \
@@ -818,11 +821,11 @@ $(ObjDir)/%.o: %.c $(ObjDir)/.dir
        $(Compile.C) $< -o $@ 
 endif
 
-$(ObjDir)/%.bc: %.cpp $(ObjDir)/.dir
+$(ObjDir)/%.bc: %.cpp $(ObjDir)/.dir $(GCCAS)
        $(Echo) "Compiling $*.cpp for $(BuildMode) build (bytecode)"
        $(BCCompile.CXX) $< -o $@ 
 
-$(ObjDir)/%.bc: %.c $(ObjDir)/.dir
+$(ObjDir)/%.bc: %.c $(ObjDir)/.dir $(GCCAS)
        $(Echo) "Compiling $*.c for $(BuildMode) build (bytecode)"
        $(BCCompile.C) $< -o $@