0
  Failed building wheel for lxml
Failed to build lxml
Installing collected packages: lxml, scrapy
  Running setup.py install for lxml
    Complete output from command C:\Python34\python.exe -c "import setuptools, 
tokenize;__file__='C:\\Users\\Family\\AppData\\Local\\Temp\\pip-build-i6gpylsx\\
lxml\\setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().
replace('\r\n', '\n'), __file__, 'exec'))" install --record C:\Users\Family\AppData
\Local\Temp\pip-jggq15oq-record\install-record.txt --single-version-externally-managed --compile:
    Building lxml version 3.4.4.
    Building without Cython.
    ERROR: b'xslt-config \x84r inte ett internt kommando, externt kommando,\r\nprogram eller kommandofil.\r\n'
    ** make sure the development packages of libxml2 and libxslt are installed **

    Using build configuration of libxslt
    running install
    running build
    running build_py
    copying src\lxml\includes\lxml-version.h -> build\lib.win32-3.4\lxml\includes
    running build_ext
    building 'lxml.etree' extension
    C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\BIN\cl.exe /c /nologo
 /Ox /MD /W3 /GS- /DNDEBUG -IC:\Users\Family\AppData\Local\Temp\pip-build-i6gpyl
sx\lxml\src\lxml\includes -IC:\Python34\include -IC:\Python34\include /Tcsrc\lxml\
lxml.etree.c /Fobuild\temp.win32-3.4\Release\src\lxml\lxml.etree.obj -w
    cl : Command line warning D9025 : overriding '/W3' with '/w'
    lxml.etree.c
    C:\Users\Family\AppData\Local\Temp\pip-build-i6gpylsx\lxml\src\lxml\includes\etree_defs.h(14) :
        fatal error C1083: Cannot open include file: 'libxml/xmlversion.h': No such file or directory
    C:\Python34\lib\distutils\dist.py:260: UserWarning: Unknown distribution option: 'bugtrack_url'
      warnings.warn(msg)
    error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio 10.0\\VC\\BIN\\cl.exe' failed with exit status 2

    ----------------------------------------
Command "C:\Python34\python.exe -c "import setuptools, tokenize;
__file__='C:\\Users\\Family\\AppData\\Local\\Temp\\pip-build-i6gpylsx\\lxml\\setup.py';
exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))"
install --record C:\Users\Family\AppData\Local\Temp\pip-jggq15oq
-record\install-record.txt --single-version-externally-managed --compile" failed
 with error code 1 in C:\Users\Family\AppData\Local\Temp\pip-build-i6gpylsx\lxml

I have Python 3.4 on a 64-bit computer. Searched a lot on stack overflow and nothing helped me. I have no idea what's wrong and do you know any solutions?

ArtOfWarfare
  • 20,617
  • 19
  • 137
  • 193
ZeZe
  • 167
  • 1
  • 14

1 Answers1

1

Scrapy does not work with Python 3 currently, but there are plans (and even work in progress) to do this port. So I would suggest you to install Python 2.7 to your computer too and install the required libraries there too.

For lxml and other libraries there are some unofficial ports for windows which you can look at here.

And sometimes you need some free Visual Studio downloaded and installed to get libraries on your windows machine which enable to compile lxml. You can find a related question on SO here.

Community
  • 1
  • 1
GHajba
  • 3,665
  • 5
  • 25
  • 35