Build instructions insufficient for building on Windows
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
lxml |
New
|
Undecided
|
Unassigned |
Bug Description
In https:/
The build from source instructions currently have this to say about building on Windows:
> Static linking on Windows
>
> Most operating systems have proper package management that makes installing current versions of libxml2 and libxslt easy. The most famous exception is Microsoft Windows, which entirely lacks these capabilities. To work around the limits of this platform, lxml's installation can download pre-built packages of the dependencies and build statically against them. Assuming you have a proper C compiler setup to build Python extensions, this should work:
>
> python setup.py bdist_wininst --static-deps
>
> It should create a windows installer in the pkg directory.
These instructions fail for me. When I attempt to run the documented command with Microsoft Visual Studio 2019 with C++ compiler installed, I get the following error:
```
C:\Program Files (x86)\Microsoft Visual Studio\
fatal error C1047: The object or library file 'libs\iconv-
LINK : fatal error LNK1257: code generation failed
```
The instructions don't give any context except to say "have a proper C compiler setup", but delving into the INSTALL docs, I see "lxml can use http:// www.zlatkovic. com/libxml. en.html" and heading over to that site, it says "All binaries have been built using C/C++ compiler version 13" but it also makes mention of "If you're using Windows 95...", so I'm not super confident in the freshness of the guidance.
At one point in my life (~13 years ago), I wrote a Python script that would build lxml from sources reliably on Windows, but I'm not sure if I still have that code. I suspect I deleted it, presuming that this project had probably formalized a process for building on Windows.