]> granicus.if.org Git - python/commitdiff
Makes embedded distribution a plain ZIP file and corrects pyd exclusion.
authorSteve Dower <steve.dower@microsoft.com>
Sat, 2 May 2015 22:32:14 +0000 (15:32 -0700)
committerSteve Dower <steve.dower@microsoft.com>
Sat, 2 May 2015 22:32:14 +0000 (15:32 -0700)
Tools/msi/make_zip.proj
Tools/msi/make_zip.py

index d47de88335b61f20b989ba25ea5fb715dd9f314a..a0f461a71dbed32c271d86b0734135f267ee49ee 100644 (file)
@@ -9,8 +9,9 @@
     <Import Project="msi.props" />
 
     <PropertyGroup>
+        <SignOutput>false</SignOutput>
         <TargetName>python-$(PythonVersion)-embed-$(ArchName)</TargetName>
-        <TargetExt>.exe</TargetExt>
+        <TargetExt>.zip</TargetExt>
         <TargetPath>$(OutputPath)\en-us\$(TargetName)$(TargetExt)</TargetPath>
         <Arguments>"$(PythonExe)" "$(MSBuildThisFileDirectory)\make_zip.py"</Arguments>
         <Arguments>$(Arguments) -e -o "$(TargetPath)" -t "$(IntermediateOutputPath)\zip_$(ArchName)" -a $(ArchName)</Arguments>
index 56d6f3807b3a7c872c141252e051d088c3f467c1..368b4ec8f0403f47359344cbf53ebc41ad55e2b6 100644 (file)
@@ -14,7 +14,19 @@ DEBUG_RE = re.compile(r'_d\.(pyd|dll|exe)$', re.IGNORECASE)
 PYTHON_DLL_RE = re.compile(r'python\d\d?\.dll$', re.IGNORECASE)
 
 def is_not_debug(p):
-    return not DEBUG_RE.search(p.name) and not TKTCL_RE.search(p.name)
+    if DEBUG_RE.search(p.name):
+        return False
+
+    if TKTCL_RE.search(p.name):
+        return False
+
+    return p.name.lower() not in {
+        '_ctypes_test.pyd',
+        '_testbuffer.pyd',
+        '_testcapi.pyd',
+        '_testimportmultiple.pyd',
+        'xxlimited.pyd',
+    }
 
 def is_not_debug_or_python(p):
     return is_not_debug(p) and not PYTHON_DLL_RE.search(p.name)
@@ -31,14 +43,6 @@ def include_in_lib(p):
         return True
 
     suffix = p.suffix.lower()
-    if suffix == '.pyd':
-        return name not in {
-            '_ctypes_test.pyd',
-            '_testbuffer.pyd',
-            '_testcapi.pyd',
-            '_testimportmultiple.pyd',
-            'xxlimited.pyd',
-        }
     return suffix not in {'.pyc', '.pyo'}
 
 def include_in_tools(p):
@@ -153,8 +157,7 @@ def main():
             subprocess.check_call([
                 str(rar),
                 "a",
-                "-m5", "-ed", "-ep1", "-s", "-r",
-                "-sfxwincon.sfx",
+                "-ed", "-ep1", "-s", "-r",
                 str(out),
                 str(temp / '*')
             ])