summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Misc/NEWS3
-rw-r--r--setup.py11
2 files changed, 8 insertions, 6 deletions
diff --git a/Misc/NEWS b/Misc/NEWS
index b08ba8f..83554f3 100644
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -35,6 +35,9 @@ Library
Build
-----
+- Issue 4601: 'make install' did not set the appropriate permissions on
+ directories.
+
- Issue 5390: Add uninstall icon independent of whether file
extensions are installed.
diff --git a/setup.py b/setup.py
index 2738eec..c42416e 100644
--- a/setup.py
+++ b/setup.py
@@ -1605,12 +1605,11 @@ class PyBuildInstallLib(install_lib):
def set_dir_modes(self, dirname, mode):
if not self.is_chmod_supported(): return
- os.walk(dirname, self.set_dir_modes_visitor, mode)
-
- def set_dir_modes_visitor(self, mode, dirname, names):
- if os.path.islink(dirname): return
- log.info("changing mode of %s to %o", dirname, mode)
- if not self.dry_run: os.chmod(dirname, mode)
+ for dirpath, dirnames, fnames in os.walk(dirname):
+ if os.path.islink(dirpath):
+ continue
+ log.info("changing mode of %s to %o", dirpath, mode)
+ if not self.dry_run: os.chmod(dirpath, mode)
def is_chmod_supported(self):
return hasattr(os, 'chmod')