Add optional code signing after merging.

This commit is contained in:
Martin v. Löwis 2009-02-13 20:51:48 +00:00
parent a63b99575e
commit 7e28b9c565
1 changed files with 6 additions and 0 deletions

View File

@ -1,5 +1,6 @@
import msilib,os,win32com,tempfile,sys
PCBUILD="PCBuild"
certname = None
from config import *
Win64 = "amd64" in PCBUILD
@ -76,3 +77,8 @@ def merge(msi, feature, rootdir, modules):
db.Commit()
merge(msi, "SharedCRT", "TARGETDIR", modules)
# certname (from config.py) should be (a substring of)
# the certificate subject, e.g. "Python Software Foundation"
if certname:
os.system('signtool sign /n "%s" /t http://timestamp.verisign.com/scripts/timestamp.dll %s' % (certname, msi))