Do not crash when dealing with invoke and unwind instructions!
[oota-llvm.git] / Makefile.rules
index af0c021234afca1de8754afcd85bec72d540b86b..5caea11356b9497d6ae756d58cc0a9c35e6c8ffb 100644 (file)
@@ -816,6 +816,12 @@ $(LLVM_OBJ_ROOT)/config.status:: $(LLVM_SRC_ROOT)/configure
        @${ECHO} "****************************************************************"
        $(VERB) exit 1
 
+# If the Makefile in the source tree has been updated, copy it over into the
+# build tree.
+Makefile :: $(BUILD_SRC_DIR)/Makefile
+       @${ECHO} "===== Updating Makefile from source dir: `dirname $<` ====="
+       cp -f $< $@
+
 #
 # Include dependencies generated from C/C++ source files, but not if we
 # are cleaning (this example taken from the GNU Make Manual).