Patch #1545507: Exclude ctypes package in Win64 MSI file.

Will backport to 2.5.
This commit is contained in:
Martin v. Löwis 2006-08-25 00:03:34 +00:00
parent 9e398cac94
commit 38325b730f
1 changed files with 8 additions and 0 deletions

View File

@ -872,6 +872,12 @@ def add_files(db):
version=version, language=lang) version=version, language=lang)
tmpfiles.append("msvcr71.dll") tmpfiles.append("msvcr71.dll")
# Check if _ctypes.pyd exists
have_ctypes = os.path.exists(srcdir+"/PCBuild/_ctypes.pyd")
if not have_ctypes:
print "WARNING: _ctypes.pyd not found, ctypes will not be included"
extensions.remove("_ctypes.pyd")
# Add all .py files in Lib, except lib-tk, test # Add all .py files in Lib, except lib-tk, test
dirs={} dirs={}
pydirs = [(root,"Lib")] pydirs = [(root,"Lib")]
@ -889,6 +895,8 @@ def add_files(db):
# data: Lib/email/test # data: Lib/email/test
# output: Lib/test # output: Lib/test
testsuite.set_current() testsuite.set_current()
elif not have_ctypes and dir == "ctypes":
continue
else: else:
default_feature.set_current() default_feature.set_current()
lib = PyDirectory(db, cab, parent, dir, dir, "%s|%s" % (parent.make_short(dir), dir)) lib = PyDirectory(db, cab, parent, dir, dir, "%s|%s" % (parent.make_short(dir), dir))