New Makefile Features:

* "dist" target now builds tar.gz, tar.bz2, and zip files suitable for
  distribution. "dist" can only be run from $(BUILD_OBJ_ROOT) and implies
  a "check".

* made the preconditions not do a recursive make and ensured that they are
  executed sequentially.

* made the messages output by the makefile be prefixed with "llvm" and the
  make level (e.g. llvm[1]: ) in the same way that make does so that the
  messages are uniform and more readable.

* Fixed the tags target so that tags depends on TAGS which contains the
  rules to build a file named TAGS

* Implemented the EXTRA_DIST feature in a few directories to make sure it
  works.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@17210 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/Makefile b/Makefile
index 0d7ca67..64cef16 100644
--- a/Makefile
+++ b/Makefile
@@ -9,13 +9,24 @@
 LEVEL = .
 DIRS = lib/System lib/Support utils lib tools 
 
+
 ifneq ($(MAKECMDGOALS),tools-only)
 DIRS += runtime
 OPTIONAL_DIRS = examples projects
 endif
 
+EXTRA_DIST := llvm.spec include configure \
+	      autoconf/AutoRegen.sh autoconf/LICENSE.TXT autoconf/README.TXT \
+	      autoconf/aclocal.m4 autoconf/config.guess autoconf/config.sub \
+	      autoconf/configure.ac autoconf/depcomp autoconf/install-sh \
+	      autoconf/ltmain.sh autoconf/missing autoconf/mkinstalldirs \
+	      autoconf/m4
 include $(LEVEL)/Makefile.common
 
+dist-hook::
+	@$(ECHO) Eliminating CVS directories from distribution
+	$(VERB) rm -rf `find $(TopDistDir) -type d -name CVS -print`
+
 test :: all
 	cd test; $(MAKE)