Fix Clang build for srcdir != objdir
authorSebastian Redl <sebastian.redl@getdesigned.at>
Sat, 14 Mar 2009 14:42:51 +0000 (14:42 +0000)
committerSebastian Redl <sebastian.redl@getdesigned.at>
Sat, 14 Mar 2009 14:42:51 +0000 (14:42 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@67008 91177308-0d34-0410-b5e6-96231b3b80d8

Makefile.rules

index 948b88099f38dbfb24894096cf7367465613fc18..351a3450601bf7c6f3c558ea3fc239907f98e8aa 100644 (file)
@@ -1478,10 +1478,10 @@ endif # LLVMC_BUILD_AUTOGENERATED_INC
 
 ifdef CLANG_BUILD_DIAGNOSTICS_INC
 
-$(ObjDir)/Diagnostic%Kinds.inc.tmp : Diagnostic%Kinds.td Diagnostic.td $(TBLGEN)
-       $(Echo) "Building Clang $(<F) diagnostic tables with tblgen"
+$(ObjDir)/Diagnostic%Kinds.inc.tmp : Diagnostic.td Diagnostic%Kinds.td $(TBLGEN)
+       $(Echo) "Building Clang $(patsubst Diagnostic%Kinds.inc.tmp,%,$(@F)) diagnostic tables with tblgen"
        $(Verb) $(MKDIR) $(@D)
-       $(Verb) $(TableGen) -gen-clang-diags-defs -clang-component=$(patsubst Diagnostic%Kinds.td,%,$(<F)) -o $(call SYSPATH, $@) Diagnostic.td
+       $(Verb) $(TableGen) -gen-clang-diags-defs -clang-component=$(patsubst Diagnostic%Kinds.inc.tmp,%,$(@F)) -o $(call SYSPATH, $@) $<
 
 endif