The bug tracker for setuptools 0.7 or higher is on BitBucket



Title easy_install broken on 64 bits Windows
Priority critical Status chatting
Superseder Nosy List bakers1, contactthedvla, frankiefillmore, lissacoffey
Assigned To Keywords needpatch

Created on 2008-05-08.09:08:36 by asmodai, last changed 2016-12-13.09:50:36 by bakers1.

File name Uploaded Type Edit Remove
64bitlauncher v2.patch jaraco, 2009-08-11.22:59:12 text/x-patch
64bitlauncher.patch jaraco, 2009-02-26.00:18:47 text/x-patch
cli-32.exe jaraco, 2009-02-26.00:18:59 application/x-sdlc
cli-64.exe jaraco, 2009-02-26.00:19:06 application/x-sdlc
gui-32.exe jaraco, 2009-02-26.00:19:13 application/x-sdlc
gui-64.exe jaraco, 2009-02-26.00:19:20 application/x-sdlc
python-fix.txt carwyn, 2009-12-26.23:33:39 text/plain
msg779 (view) Author: bakers1 Date: 2016-12-13.09:50:35
brilliant, this will come in handy for my work on python PAYG system hosted on
msg777 (view) Author: frankiefillmore Date: 2016-11-02.16:19:12
msg767 (view) Author: contactthedvla Date: 2016-10-04.09:04:03
msg758 (view) Author: lissacoffey Date: 2016-04-22.07:25:53
A less than perfect workaround is to use '' instead of the
executable.  I believe using the script requires that the .py file extension is
associated with the appropriate python installation, or that the script be run
explicitly from the correct Python installation.  e.g.
"C:\Program Files\Python26\Python.exe" "C:\Program
Files\Python26\Scripts\" <your options>

Not the easiest workaround, but at least enough to get by until someone has time
to build a 64-bit version of setuptools.
msg482 (view) Author: carwyn Date: 2009-12-27.20:44:35
Thanks for the reply. Moved to exiting bug at
msg481 (view) Author: pje Date: 2009-12-27.13:57:49
This (new) issue can't be fixed in setuptools; it's a core distutils problem and
should be reported to the main Python tracker (as I said on the distutils-sig list).

The issue is with the .exe header used by the bdist_wininst command; setuptools
doesn't generate this wrapper itself; it uses the one supplied by the distutils,
so non-setuptools packages will have the same problem.  Without a fixed .exe
header in the Python installation, *all* bdist_wininst-generated .exe installers
(setuptools or distutils) will have the same problem.

Please report this issue to the main Python bug tracker, so that distutils,
Distribute, etc. will all get fixed as well as setuptools, hopefully in a 2.6.5
or similar release of Python.  In the meantime, the workaround will have to be
used.  (But if there's a fix released by the core Python team, I can certainly
re-release setuptools based on it.)
msg480 (view) Author: sorin Date: 2009-12-27.13:35:47
I should mention that the previous is just a temporary workaround. setuptools
must be able to locate both locations, trying first the native one (x64) and as
fallback Wow6432Node key.
msg479 (view) Author: carwyn Date: 2009-12-26.23:33:39
This is almost working. As of 0.6c11 on Windows 7 64 bit the
setuptools-0.6c11.win32-py2.6.exe installer fails reporting it can't find the
location of python in the registry. (Python is python-2.6.4.amd64.msi)

It seems to be looking for it in:


.. rather than the:

.. that the python installer puts in the registry.

See the following for more information:

Adding the attached python-fix.reg to the registry before running the setuptools
installer works around the problem.
msg432 (view) Author: pje Date: 2009-10-19.19:40:31
setuptools 0.6c10 is released with an alternate fix for this issue, that uses a
single .exe for both 32/64 bits (by not using LoadLibrary on the target Python).
 Please re-open if this doesn't resolve the issue.  Thanks!
msg356 (view) Author: agronholm Date: 2009-09-25.21:27:07
I have committed this patch with the appropriate files in the 0.6 maintenance
branch of distribute (the successor to setuptools).
Bitbucket link:

There is a bootstrapper script that fetches and installs distribute and replaces
any existing setuptools installation with a fake package.
Script link:

We are about to release v0.8.2 very soon, unless someone comes up with an urgent
msg349 (view) Author: sorin Date: 2009-08-23.09:56:54
Because the patch code is not in the SCM installing using still fails.
msg347 (view) Author: sorin Date: 2009-08-21.16:26:27
The package worked and now I would like to see this included in the normal
distribution package. This will spare others time.
msg346 (view) Author: jaraco Date: 2009-08-21.12:39:43
I've put a zip of the source for setuptools-0.6c9 with two patches, one for
issue2 (this issue) and another for issue64. You can grab it at . In
addition to the patches, I've renamed the version to
"setuptools-0.6c9_issue2_issue64", so it will install as separate from other
builds. Let me know if this doesn't work for you.
msg345 (view) Author: droolz Date: 2009-08-21.09:48:49
I'm having no joy installing the patch [my knowledge of this is practically
non-existent]. Is there any chance that anyone could host the patched source so
I can get hold of it? Aprreciate this is a big ask. My email is jules at many thanks.
msg344 (view) Author: droolz Date: 2009-08-15.13:09:04
Another nod of agreement from me. This needs to be done ASAP, non-64 bit windows
support is a real pain.
msg343 (view) Author: nbolton Date: 2009-08-15.12:25:19
I confirm this is very important, and should be solved asap.
msg342 (view) Author: sorin Date: 2009-08-15.10:41:29
Current bug does prevent installation of all Python packages that are using
setuptools on Windows x64. 

I confirm that patch v2 is working (tested on Windows 7 x64) and we should
commit this to the trunk ASAP and also to current released version (0.6c9).

Also, I consider this issue critical because it does make the product unusable
for a big amount of users without any workarounds.

I do not have commit access, so we need help from somebody that does.

In addition we should release a new version to that will include this patch.
msg341 (view) Author: jaraco Date: 2009-08-11.22:59:12
I realized my initial patch didn't include the changes to to
accommodate the new exe files.  This v2 patch does.
msg248 (view) Author: jaraco Date: 2009-02-26.00:18:46
Here's a patch that enables building the gui and cli.exe files on Visual Studio
2008.  I found that if I used the WinMain entry point, another command-window
would open during the spawnv, so I updated the entry point.  This may cause
problems with gui.exe which I have not tested.

The added batch file "msvc-build-launcher.cmd" will compile 32- and 64-bit
versions of each executable.

I'll be attaching the files I built.  They're more than 10x the size of the
other files, so any suggestions on making them smaller would be appreciated.
msg232 (view) Author: jaraco Date: 2009-01-28.13:08:10
A less than perfect workaround is to use '' instead of the
executable.  I believe using the script requires that the .py file extension is
associated with the appropriate python installation, or that the script be run
explicitly from the correct Python installation.  e.g.
"C:\Program Files\Python26\Python.exe" "C:\Program
Files\Python26\Scripts\" <your options>

Not the easiest workaround, but at least enough to get by until someone has time
to build a 64-bit version of setuptools.
msg204 (view) Author: droolz Date: 2008-11-14.11:16:50
This problem is causing me a lot of issues. My knowledge of compilers is basic
to say the least, but I do have access to 64bit windows compilers and can help
out if someone can give me some pointers as to how to do it. I've tried mucking
around with launcher.h but it seems very gcc specific, and I've no idea of how
to get it to work with cl.exe.
msg75 (view) Author: pje Date: 2008-08-05.15:41:40
Supporting this will probably require somebody with a 64-bit windows to do
builds, or else provide a cross-compile procedure.  There will also need to be
some sort of patch to handle using two versions of the .exe wrappers.  Either
that, or somebody will need to come up with a way other than LoadLibraryEx to
verify the executability of the Python executable.  (Note that this would
probably also fix the outstanding issue where the .exe wrappers don't work on
Vista without admin privs, probably because of the same LoadLibraryEx call.)
msg2 (view) Author: asmodai Date: 2008-05-08.09:08:36
As I reported in
easy_install on a 64 bits Python on a 64 bits Windows is broken in that it gives
the following error:

Cannot find Python executable C:\Python25\python.exe

I believe that due to cli.exe and gui.exe (built from launcher.c) being 32-bits
executables they are trying to use 32-bit specific calls which fail on a 64 bits
As Mark Hammond said in "I suspect
that the issue is that a 32bit cli.exe or gui.exe is attempting to LoadLibrary a
64bit executable and failing (specifically, loadable_exe() in launcher.c)"
Date User Action Args
2016-12-13 09:50:36bakers1setnosy: + bakers1
messages: + msg779
2016-11-02 16:19:13frankiefillmoresetnosy: + frankiefillmore
messages: + msg777
2016-10-04 09:04:04contactthedvlasetnosy: + contactthedvla
messages: + msg767
2016-04-22 07:25:53lissacoffeysetstatus: resolved -> chatting
nosy: + lissacoffey, - asmodai, jaraco, pje, droolz, srid, sorin, nbolton, agronholm, carwyn
messages: + msg758
2009-12-27 20:44:43carwynsetstatus: chatting -> resolved
2009-12-27 20:44:35carwynsetstatus: resolved -> chatting
messages: + msg482
2009-12-27 13:57:50pjesetstatus: chatting -> resolved
messages: + msg481
2009-12-27 13:35:47sorinsetstatus: unread -> chatting
messages: + msg480
2009-12-26 23:33:40carwynsetstatus: resolved -> unread
files: + python-fix.txt
messages: + msg479
nosy: + carwyn
2009-10-19 19:40:31pjesetstatus: in-progress -> resolved
messages: + msg432
2009-09-25 21:27:08agronholmsetnosy: + agronholm
messages: + msg356
2009-08-23 09:56:54sorinsetmessages: + msg349
2009-08-21 16:26:27sorinsetmessages: + msg347
2009-08-21 12:39:43jaracosetmessages: + msg346
2009-08-21 09:48:50droolzsetmessages: + msg345
2009-08-15 13:09:04droolzsetmessages: + msg344
2009-08-15 12:25:19nboltonsetnosy: + nbolton
messages: + msg343
2009-08-15 10:41:30sorinsetpriority: urgent -> critical
status: chatting -> in-progress
messages: + msg342
nosy: + sorin
2009-08-11 22:59:12jaracosetfiles: + 64bitlauncher v2.patch
messages: + msg341
2009-05-19 19:52:46sridsetnosy: + srid
2009-02-26 00:19:20jaracosetfiles: + gui-64.exe
2009-02-26 00:19:13jaracosetfiles: + gui-32.exe
2009-02-26 00:19:06jaracosetfiles: + cli-64.exe
2009-02-26 00:18:59jaracosetfiles: + cli-32.exe
2009-02-26 00:18:47jaracosetfiles: + 64bitlauncher.patch
messages: + msg248
2009-01-28 13:08:11jaracosetmessages: + msg232
2009-01-28 13:03:36jaracosetnosy: + jaraco
2008-11-14 11:16:51droolzsetnosy: + droolz
messages: + msg204
2008-08-05 15:41:40pjesetstatus: unread -> chatting
nosy: + pje
messages: + msg75
keyword: + needpatch
2008-05-08 09:08:36asmodaicreate