summaryrefslogtreecommitdiff
path: root/Tools
diff options
context:
space:
mode:
authorSteve Dower <steve.dower@microsoft.com>2016-09-09 09:17:35 -0700
committerSteve Dower <steve.dower@microsoft.com>2016-09-09 09:17:35 -0700
commite74ae1493c69617408dcd5769b110b8e1ad8a468 (patch)
tree0feb990a04b2fdad0cd14875e7c13b3d87c2921f /Tools
parentbd50890d088dd1359af4b59580583382dc57a6b1 (diff)
downloadcpython-e74ae1493c69617408dcd5769b110b8e1ad8a468.tar.gz
Changes pyvenv.cfg trick into an actual sys.path file.
Diffstat (limited to 'Tools')
-rw-r--r--Tools/msi/make_zip.py11
1 files changed, 8 insertions, 3 deletions
diff --git a/Tools/msi/make_zip.py b/Tools/msi/make_zip.py
index 0e8a4a69bb..6c43256662 100644
--- a/Tools/msi/make_zip.py
+++ b/Tools/msi/make_zip.py
@@ -46,6 +46,10 @@ EXCLUDE_FILE_FROM_LIBS = {
'python3stub',
}
+EXCLUDED_FILES = {
+ 'pyshellext',
+}
+
def is_not_debug(p):
if DEBUG_RE.search(p.name):
return False
@@ -53,7 +57,7 @@ def is_not_debug(p):
if TKTCL_RE.search(p.name):
return False
- return p.stem.lower() not in DEBUG_FILES
+ return p.stem.lower() not in DEBUG_FILES and p.stem.lower() not in EXCLUDED_FILES
def is_not_debug_or_python(p):
return is_not_debug(p) and not PYTHON_DLL_RE.search(p.name)
@@ -209,8 +213,9 @@ def main():
copied = copy_to_layout(temp / t.rstrip('/'), rglob(s, p, c))
print('Copied {} files'.format(copied))
- with open(str(temp / 'pyvenv.cfg'), 'w') as f:
- print('applocal = true', file=f)
+ with open(str(temp / 'sys.path'), 'w') as f:
+ print('python{0.major}{0.minor}.zip'.format(sys.version_info), file=f)
+ print('.', file=f)
if out:
total = copy_to_layout(out, rglob(temp, '**/*', None))