|
|
@ -106,7 +106,7 @@ def set_chmod(path, mode, dir_fd=None, follow_symlinks=True): |
|
|
|
os.chmod(path, mode, dir_fd=dir_fd) |
|
|
|
os.chmod(path, mode, dir_fd=dir_fd) |
|
|
|
|
|
|
|
|
|
|
|
def sanitize_permissions(path, umask): |
|
|
|
def sanitize_permissions(path, umask): |
|
|
|
if umask is None: |
|
|
|
if umask == 'preserve': |
|
|
|
return |
|
|
|
return |
|
|
|
new_perms = 0o777 if is_executable(path, follow_symlinks=False) else 0o666 |
|
|
|
new_perms = 0o777 if is_executable(path, follow_symlinks=False) else 0o666 |
|
|
|
new_perms &= ~umask |
|
|
|
new_perms &= ~umask |
|
|
@ -332,7 +332,7 @@ class Installer: |
|
|
|
d.destdir = os.environ.get('DESTDIR', '') |
|
|
|
d.destdir = os.environ.get('DESTDIR', '') |
|
|
|
d.fullprefix = destdir_join(d.destdir, d.prefix) |
|
|
|
d.fullprefix = destdir_join(d.destdir, d.prefix) |
|
|
|
|
|
|
|
|
|
|
|
if d.install_umask is not None: |
|
|
|
if d.install_umask != 'preserve': |
|
|
|
os.umask(d.install_umask) |
|
|
|
os.umask(d.install_umask) |
|
|
|
|
|
|
|
|
|
|
|
self.did_install_something = False |
|
|
|
self.did_install_something = False |
|
|
|