How to install Python package from source on Windows

Gregory Ewing greg.ewing at canterbury.ac.nz
Mon May 22 02:17:51 EDT 2017


bartc wrote:
> The 'one-file' idea is one approach to simplifying the building of 
> open-source applications. Probably, it's more suited to those who just 
> want to try out, or use, a bit of software.

But on Windows, that use case is normally covered by installing
a *binary*, not compiling from source. If the developer is in a
position to supply a source distribution that's pre-configured
to compile on Windows with no further effort, then it's only
one small step for him to compile it himself and distribute
the binary.

> (The GMP library, for example, has no official binary releases. You have 
> to build from source,

So using it on Windows isn't supported very well. This is
in contrast to Python, for which a pretty comprehensive set
of Windows binaries *is* available.

> A one-file CPython might be under 250Kloc, not too bad to play with, but 
> I'm not sure it would work as there are multiple binary files to build, 
> not a single executable.

The number of files isn't really the issue. The point is
that it wouldn't really be source in the sense of something
human-editable. If you're not going to edit it, then it
might as well be a binary.

-- 
Greg



More information about the Python-list mailing list