Read about our upcoming Code of Conduct on this issue

Commit c3e3c370 authored by Matt Harbison's avatar Matt Harbison
Browse files

setup: stop packaging python3.dll and python3X.dll in the wheel distribution

Now that exewrapper is smart enough to find the DLLs it needs without help from
the build script, backout ed286d150aa8 and 2960b7fac966.  Note that this will
require deleting the build/ directory to actually remove it
from the final wheel.

Differential Revision:
parent 67d14d4e036c
......@@ -780,9 +780,6 @@ class buildhgexe(build_ext):
pythonlib = None
dir = os.path.dirname(self.get_ext_fullpath('dummy'))
self.hgtarget = os.path.join(dir, 'hg')
if getattr(sys, 'dllhandle', None):
# Different Python installs can have different Python library
# names. e.g. the official CPython distribution uses pythonXY.dll
......@@ -808,35 +805,6 @@ class buildhgexe(build_ext):
pythonlib = dllbasename[:-4]
# Copy the pythonXY.dll next to the binary so that it runs
# without tampering with PATH.
fsdecode = lambda x: x
if sys.version_info[0] >= 3:
fsdecode = os.fsdecode
dest = os.path.join(
if not os.path.exists(dest):
shutil.copy(buf.value, dest)
# Also overwrite python3.dll so that hgext.git is usable.
# TODO: also handle the MSYS flavor
if sys.version_info[0] >= 3:
python_x = os.path.join(
if os.path.exists(python_x):
dest = os.path.join(
shutil.copy(python_x, dest)
if not pythonlib:
'could not determine Python DLL filename; assuming pythonXY'
......@@ -859,6 +827,8 @@ class buildhgexe(build_ext):
dir = os.path.dirname(self.get_ext_fullpath('dummy'))
self.hgtarget = os.path.join(dir, 'hg')
objects, self.hgtarget, libraries=[], output_dir=self.build_temp
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment