[Python-checkins] r66304 - in python/trunk: Misc/NEWS Tools/msi/merge.py

martin.v.loewis python-checkins at python.org
Mon Sep 8 14:02:46 CEST 2008


Author: martin.v.loewis
Date: Mon Sep  8 14:02:45 2008
New Revision: 66304

Log:
Allow passing the MSI file name to merge.py.


Modified:
   python/trunk/Misc/NEWS
   python/trunk/Tools/msi/merge.py

Modified: python/trunk/Misc/NEWS
==============================================================================
--- python/trunk/Misc/NEWS	(original)
+++ python/trunk/Misc/NEWS	Mon Sep  8 14:02:45 2008
@@ -125,6 +125,8 @@
 Build
 -----
 
+- Allow passing the MSI file name to merge.py.
+
 - Issue #3758: Rename the 'check' target to 'patchcheck' so as to not clash 
   with GNU build target guidelines.
 

Modified: python/trunk/Tools/msi/merge.py
==============================================================================
--- python/trunk/Tools/msi/merge.py	(original)
+++ python/trunk/Tools/msi/merge.py	Mon Sep  8 14:02:45 2008
@@ -1,16 +1,19 @@
-import msilib,os,win32com,tempfile
+import msilib,os,win32com,tempfile,sys
 PCBUILD="PCBuild"
 from config import *
 
 Win64 = "amd64" in PCBUILD
 
 mod_dir = os.path.join(os.environ["ProgramFiles"], "Common Files", "Merge Modules")
+msi = None
+if len(sys.argv)==2:
+    msi = sys.argv[1]
 if Win64:
     modules = ["Microsoft_VC90_CRT_x86.msm", "policy_8_0_Microsoft_VC80_CRT_x86_x64.msm"]
-    msi = "python-%s.amd64.msi" % full_current_version
+    if not msi: msi = "python-%s.amd64.msi" % full_current_version
 else:
     modules = ["Microsoft_VC90_CRT_x86.msm","policy_8_0_Microsoft_VC80_CRT_x86.msm"]
-    msi = "python-%s.msi" % full_current_version
+    if not msi: msi = "python-%s.msi" % full_current_version
 for i, n in enumerate(modules):
     modules[i] = os.path.join(mod_dir, n)
 


More information about the Python-checkins mailing list