Fix PR835 so that touching tblgen in a way that doesn't affect intrinsic
authorChris Lattner <sabre@nondot.org>
Thu, 20 Jul 2006 16:44:21 +0000 (16:44 +0000)
committerChris Lattner <sabre@nondot.org>
Thu, 20 Jul 2006 16:44:21 +0000 (16:44 +0000)
generation does not rebuild files that just use intrinsic info.

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

lib/VMCore/Makefile

index 6c2137eaddb0acea78b09ee2112eb9a9ecd9d90b..af3ae403b93d0d6567716071fab5a569d7568022 100644 (file)
@@ -19,10 +19,13 @@ GENFILE:=$(PROJ_SRC_ROOT)/include/llvm/Intrinsics.gen
 INTRINSICTD  := $(PROJ_SRC_ROOT)/include/llvm/Intrinsics.td
 INTRINSICTDS := $(wildcard $(PROJ_SRC_ROOT)/include/llvm/Intrinsics*.td)
 
-$(GENFILE): $(INTRINSICTDS) $(TBLGEN)
-       $(Echo) Building Intrinsics.gen from Intrinsics.td
+$(ObjDir)/Intrinsics.gen.tmp: $(INTRINSICTDS) $(TBLGEN)
+       $(Echo) Building Intrinsics.gen.tmp from Intrinsics.td
        $(Verb) $(TableGen) $(INTRINSICTD) -o $@ -gen-intrinsic
 
+$(GENFILE): $(ObjDir)/Intrinsics.gen.tmp
+       $(Verb) $(CMP) -s $@ $< || $(CP) $< $@
+
 install-local:: $(GENFILE)
        $(Echo) Installing $(PROJ_includedir)/llvm/Intrinsics.gen
        $(Verb) $(DataInstall) $(GENFILE) $(PROJ_includedir)/llvm/Intrinsics.gen