FAQ
I want to use the lxml library, but can't get it to work on Windows.

The following will not work:
* import libxml2
* import libxslt
* from lxml import etree

Here's the instructions:
http://codespeak.net/lxml/installation.html

* So, I run "easy_install lxml" -- that works!
* Now, it says I need to install libxml2 and libxslt... how do I do that?
...so, I download the libxml2 and libxslt pre-built Windows binaries here:
http://www.zlatkovic.com/pub/libxml/
Now what do I do with them?
I opened the zip files and copied the bin directories to Python\Lib ... like this: Python\Lib\libxml2\libxml2.dll ... that doesn't work. I copy just dll to Python\DLLs ... that doesn't work.

What now?
_________________________________________________________________
Bing brings you maps, menus, and reviews organized in one place.
http://www.bing.com/search?q=restaurants&form=MFESRP&publ=WLHMTAG&crea=TEXT_MFESRP_Local_MapsMenu_Resturants_1x1
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20091102/a4d109d8/attachment.htm>

Search Discussions

  • Nat Williams at Nov 2, 2009 at 6:06 pm

    On Mon, Nov 2, 2009 at 9:41 AM, Kevin Ar18 wrote:

    I want to use the lxml library, but can't get it to work on Windows.

    The following will not work:
    * import libxml2
    * import libxslt
    * from lxml import etree

    Here's the instructions:
    http://codespeak.net/lxml/installation.html

    * So, I run "easy_install lxml" -- that works!
    * Now, it says I need to install libxml2 and libxslt... how do I do that?
    ...so, I download the libxml2 and libxslt pre-built Windows binaries here:
    http://www.zlatkovic.com/pub/libxml/
    Now what do I do with them?
    I opened the zip files and copied the bin directories to Python\Lib ...
    like this: Python\Lib\libxml2\libxml2.dll ... that doesn't work. I copy just
    dll to Python\DLLs ... that doesn't work.

    What now?
    According to the lxml installation instructions you linked, the windows lxml
    binary is statically linked and you do not need to install the libraries
    separately. If 'from lxml import etree' works, then you're done.

    libxml2 and libxslt are C libraries, not things that you can or would
    import. The joy of lxml is not having to deal with those libraries on your
    own.

    Nat
    -------------- next part --------------
    An HTML attachment was scrubbed...
    URL: <http://mail.python.org/pipermail/python-list/attachments/20091102/aa5a962c/attachment.htm>
  • Kevin Ar18 at Nov 2, 2009 at 8:44 pm
    <eb280f6e0911021006t785e7767tbf837dd239b7875e at mail.gmail.com>
    Content-Type: text/plain; charset="iso-8859-1"
    Content-Transfer-Encoding: quoted-printable
    MIME-Version: 1.0

    According to the lxml installation instructions you linked,
    the windows lxml binary is statically linked and you do not
    need to install the libraries separately.
    The install instructions say" "You need libxml2 and libxslt" and then links to where to download the binaries; this means I need to install separately, right? If not, those are aweful instructions. :)
    I can download the binaries, but I don't know where or how to install them? Is there any instructions anywhere?
    If 'from lxml import etree' works, then you're done.
    It doesn't work.
    _________________________________________________________________
    New Windows 7: Find the right PC for you.
    http://www.microsoft.com/windows/pc-scout/default.aspx?CBID=wl&ocid=PID24727::T:WLMTAGL:ON:WL:en-US:WWL_WIN_pcscout:112009
  • Stefan Behnel at Nov 4, 2009 at 1:41 pm

    Kevin Ar18, 02.11.2009 21:44:
    According to the lxml installation instructions you linked,
    the windows lxml binary is statically linked and you do not
    need to install the libraries separately.
    The install instructions say" "You need libxml2 and libxslt" and then links> to where to download the binaries; this means I need to install separate> ly, right? If not, those are aweful instructions. :)
    Not being able to scroll down half a page (to the section titled "MS
    Windows") is not an excuse for blaming the docs.

    I can download the binaries, but I don't know where or how to install the> m? Is there any instructions anywhere?
    Yes, see the short section titled "Installation" at the top of the
    installation instructions page.

    Stefan

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
grouppython-list @
categoriespython
postedNov 2, '09 at 3:41p
activeNov 4, '09 at 1:41p
posts4
users3
websitepython.org

People

Translate

site design / logo © 2022 Grokbase