diff options
Diffstat (limited to 'setuptools/command/install_lib.py')
| -rw-r--r-- | setuptools/command/install_lib.py | 12 | 
1 files changed, 7 insertions, 5 deletions
diff --git a/setuptools/command/install_lib.py b/setuptools/command/install_lib.py index 747fbabb..d7e117f0 100644 --- a/setuptools/command/install_lib.py +++ b/setuptools/command/install_lib.py @@ -1,6 +1,7 @@  import distutils.command.install_lib as orig  import os +  class install_lib(orig.install_lib):      """Don't add compiled flags to filenames of non-Python files""" @@ -15,20 +16,20 @@ class install_lib(orig.install_lib):          exclude = {}          nsp = self.distribution.namespace_packages          svem = (nsp and self.get_finalized_command('install') -            .single_version_externally_managed) +                .single_version_externally_managed)          if svem:              for pkg in nsp:                  parts = pkg.split('.')                  while parts:                      pkgdir = os.path.join(self.install_dir, *parts)                      for f in '__init__.py', '__init__.pyc', '__init__.pyo': -                        exclude[os.path.join(pkgdir,f)] = 1 +                        exclude[os.path.join(pkgdir, f)] = 1                      parts.pop()          return exclude      def copy_tree( -        self, infile, outfile, -        preserve_mode=1, preserve_times=1, preserve_symlinks=0, level=1 +            self, infile, outfile, +            preserve_mode=1, preserve_times=1, preserve_symlinks=0, level=1      ):          assert preserve_mode and preserve_times and not preserve_symlinks          exclude = self.get_exclusions() @@ -45,7 +46,8 @@ class install_lib(orig.install_lib):          def pf(src, dst):              if dst in exclude: -                log.warn("Skipping installation of %s (namespace package)",dst) +                log.warn("Skipping installation of %s (namespace package)", +                         dst)                  return False              log.info("copying %s -> %s", src, os.path.dirname(dst))  | 
