简体   繁体   English

如何安装gphoto2?

[英]How to install gphoto2?

Whenever I try to install gphoto2 using pip this error message pops up: 每当我尝试使用pip安装gphoto2时,都会弹出此错误消息:


C:\\Python27>pip install gphoto2 C:\\ Python27> pip安装gphoto2

Collecting gphoto2
  Using cached https://files.pythonhosted.org/packages/13/20/16f4e17e0d799199c84
a7d3e4f181232071383acf71912da44de015b1812/gphoto2-1.8.3.tar.gz
Complete output from command python setup.py egg_info:
ERROR: command "pkg-config --modversion libgphoto2" failed
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "C:\Users\MACIE_~1\AppData\Local\Temp\pip-install-xybqgvtu\gphoto2\se
tup.py", line 38, in <module>
    cmd, stderr=FNULL, universal_newlines=True).split('.')
  File "c:\users\macie_000\appdata\local\programs\python\python37\lib\subpro
cess.py", line 376, in check_output
    **kwargs).stdout
  File "c:\users\macie_000\appdata\local\programs\python\python37\lib\subpro
cess.py", line 453, in run
    with Popen(*popenargs, **kwargs) as process:
  File "c:\users\macie_000\appdata\local\programs\python\python37\lib\subpro
cess.py", line 756, in __init__
    restore_signals, start_new_session)
  File "c:\users\macie_000\appdata\local\programs\python\python37\lib\subpro
cess.py", line 1155, in _execute_child
    startupinfo)
FileNotFoundError: [WinError 2] Nie można odnaleźć określonego pliku

    ----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in C:\Users\MACIE_~1
\AppData\Local\Temp\pip-install-xybqgvtu\gphoto2\

How can I fix this? 我怎样才能解决这个问题?

Try the standalone version from sourceforge. 尝试使用sourceforge的独立版本。 1) download libusb & gphoto http://sourceforge.net/projects/libusb-win32/files/libusb-win32-releases/ 1)下载libusb和gphoto http://sourceforge.net/projects/libusb-win32/files/libusb-win32-releases/

https://code.google.com/p/scan-manager/downloads/detail?name=gphoto-2.4.14-win32-build2.zip&can=2&q= https://code.google.com/p/scan-manager/downloads/detail?name=gphoto-2.4.14-win32-build2.zip&can=2&q=

2) unzip both files 2)解压缩两个文件

3) connect your camera and switch it on 3)连接相机并开启

4) install libusb run inf-wizard from libusb/bin folder, select your camera and click install 4)从libusb / bin文件夹安装libusb运行inf-wizard ,选择您的相机并单击install

5) run gphoto2 from gphoto2/bin folder 5)从gphoto2 / bin文件夹运行gphoto2

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM