pyGObject安装错误

时间:2018-04-05 16:16:52

标签: pygobject failed-installation

我不小心删除了“pyGObject”#39;来自python3.6解释器的包。尝试重新安装后,我收到以下错误消息。

C:\WINDOWS\system32>pip install pygobject
Collecting pygobject
  Using cached PyGObject-3.28.2.tar.gz
Collecting pycairo>=1.11.1 (from pygobject)
  Using cached pycairo-1.16.3.tar.gz
Building wheels for collected packages: pygobject, pycairo
  Running setup.py bdist_wheel for pygobject ... error
  Complete output from command "c:\program files\python\python36\python.exe" -u -c "import setuptools, tokenize;__file__='C:\\Users\\ISHARA~1\\AppData\\Local\\Temp\\pip-build-c0j2dbt2\\pygobject\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d 
  . 
  .
  .
  copying gi\overrides\__init__.py -> build\lib.win-amd64-3.6\gi\overrides
  running build_ext
  pycairo: new API
  Traceback (most recent call last):
    File "<string>", line 1, in <module>
    File "C:\Users\ISHARA~1\AppData\Local\Temp\pip-build-c0j2dbt2\pygobject\setup.py", line 840, in <module>
      main()
    .
    .
    .
    File "C:\Users\ISHARA~1\AppData\Local\Temp\pip-build-c0j2dbt2\pygobject\setup.py", line 532, in find_new_api
      import cairo
  ModuleNotFoundError: No module named 'cairo'

  ----------------------------------------
  Failed building wheel for pygobject
  .
  .
  .
  c:\users\ishara madhawa\appdata\local\temp\pip-build-c0j2dbt2\pycairo\cairo\pycairo.h(37): fatal error C1083: Cannot open include file: 'cairo.h': No such file or directory
  error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio 14.0\\VC\\BIN\\x86_amd64\\cl.exe' failed with exit status 2

    .
    .
    .
    creating build\temp.win-amd64-3.6\Release\cairo
    C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\BIN\x86_amd64\cl.exe /c /nologo /Ox /W3 /GL /DNDEBUG /MD -DPYCAIRO_VERSION_MAJOR=1 -DPYCAIRO_VERSION_MINOR=16 -DPYCAIRO_VERSION_MICRO=3 "-Ic:\program files\python\python36\include" "-Ic:\program files\python\python36\include" "-IC:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\INCLUDE" "-IC:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\ATLMFC\INCLUDE" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10240.0\ucrt" "-IC:\Program Files (x86)\Windows Kits\NETFXSDK\4.6.1\include\um" "-IC:\Program Files (x86)\Windows Kits\8.1\include\\shared" "-IC:\Program Files (x86)\Windows Kits\8.1\include\\um" "-IC:\Program Files (x86)\Windows Kits\8.1\include\\winrt" /Tccairo/device.c /Fobuild\temp.win-amd64-3.6\Release\cairo/device.obj
    device.c
    c:\users\ishara madhawa\appdata\local\temp\pip-build-c0j2dbt2\pycairo\cairo\pycairo.h(37): fatal error C1083: Cannot open include file: 'cairo.h': No such file or directory
    error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio 14.0\\VC\\BIN\\x86_amd64\\cl.exe' failed with exit status 2

    ----------------------------------------
Command ""c:\program files\python\python36\python.exe" -u -c "import setuptools, tokenize;__file__='C:\\Users\\ISHARA~1\\AppData\\Local\\Temp\\pip-build-c0j2dbt2\\pycairo\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record C:\Users\ISHARA~1\AppData\Local\Temp\pip-qffygonq-record\install-record.txt --single-version-externally-managed --compile" failed with error code 1 in C:\Users\ISHARA~1\AppData\Local\Temp\pip-build-c0j2dbt2\pycairo\

请任何人帮我解决这个错误吗?

0 个答案:

没有答案