Make setup.py less chatty by default.

This is a conservative version of SF patch 504889.  It uses the log
module instead of calling print in various places, and it ignores the
verbose argument passed to many functions and set as an attribute on
some objects.  Instead, it uses the verbosity set on the logger via
the command line.

The log module is now preferred over announce() and warn() methods
that exist only for backwards compatibility.

XXX This checkin changes a lot of modules that have no test suite and
aren't exercised by the Python build process.  It will need
substantial testing.
diff --git a/Lib/distutils/file_util.py b/Lib/distutils/file_util.py
index 14772fb..56b1fae 100644
--- a/Lib/distutils/file_util.py
+++ b/Lib/distutils/file_util.py
@@ -9,7 +9,7 @@
 
 import os
 from distutils.errors import DistutilsFileError
-
+from distutils import log
 
 # for generating verbose output in 'copy_file()'
 _copy_action = { None:   'copying',
@@ -73,7 +73,6 @@
 
 # _copy_file_contents()
 
-
 def copy_file (src, dst,
                preserve_mode=1,
                preserve_times=1,
@@ -90,8 +89,7 @@
     'preserve_times' is true (the default), the last-modified and
     last-access times are copied as well.  If 'update' is true, 'src' will
     only be copied if 'dst' does not exist, or if 'dst' does exist but is
-    older than 'src'.  If 'verbose' is true, then a one-line summary of the
-    copy will be printed to stdout.
+    older than 'src'.
 
     'link' allows you to make hard links (os.link) or symbolic links
     (os.symlink) instead of copying: set it to "hard" or "sym"; if it is
@@ -127,20 +125,18 @@
         dir = os.path.dirname(dst)
 
     if update and not newer(src, dst):
-        if verbose:
-            print "not copying %s (output up-to-date)" % src
-        return (dst, 0)
+        log.debug("not copying %s (output up-to-date)", src)
+        return dst, 0
 
     try:
         action = _copy_action[link]
     except KeyError:
         raise ValueError, \
               "invalid value '%s' for 'link' argument" % link
-    if verbose:
-        if os.path.basename(dst) == os.path.basename(src):
-            print "%s %s -> %s" % (action, src, dir)
-        else:
-            print "%s %s -> %s" % (action, src, dst)
+    if os.path.basename(dst) == os.path.basename(src):
+        log.info("%s %s -> %s", action, src, dir)
+    else:
+        log.info("%s %s -> %s", action, src, dst)
 
     if dry_run:
         return (dst, 1)
@@ -197,8 +193,7 @@
     from os.path import exists, isfile, isdir, basename, dirname
     import errno
 
-    if verbose:
-        print "moving %s -> %s" % (src, dst)
+    log.info("moving %s -> %s", src, dst)
 
     if dry_run:
         return dst