您好,登錄后才能下訂單哦!
這篇文章主要講解了解決Linux下遇到PyCurl的錯誤,內容清晰明了,對此有興趣的小伙伴可以學習一下,相信大家閱讀完之后會有幫助。
Could not run curl-config 的解決方式
Downloading/unpacking pycurl (from pyspider) Downloading pycurl-7.19.5.1.tar.gz (142kB): 142kB downloaded Running setup.py (path:/tmp/pip-build-DuBGJ5/pycurl/setup.py) egg_info for package pycurl Traceback (most recent call last): File "<string>", line 17, in <module> File "/tmp/pip-build-DuBGJ5/pycurl/setup.py", line 634, in <module> ext = get_extension(split_extension_source=split_extension_source) File "/tmp/pip-build-DuBGJ5/pycurl/setup.py", line 392, in get_extension ext_config = ExtensionConfiguration() File "/tmp/pip-build-DuBGJ5/pycurl/setup.py", line 65, in __init__ self.configure() File "/tmp/pip-build-DuBGJ5/pycurl/setup.py", line 100, in configure_unix raise ConfigurationError(msg) __main__.ConfigurationError: Could not run curl-config: [Errno 2] No such file or directory Complete output from command python setup.py egg_info: Traceback (most recent call last): File "<string>", line 17, in <module> File "/tmp/pip-build-DuBGJ5/pycurl/setup.py", line 634, in <module> ext = get_extension(split_extension_source=split_extension_source) File "/tmp/pip-build-DuBGJ5/pycurl/setup.py", line 392, in get_extension ext_config = ExtensionConfiguration() File "/tmp/pip-build-DuBGJ5/pycurl/setup.py", line 65, in __init__ self.configure() File "/tmp/pip-build-DuBGJ5/pycurl/setup.py", line 100, in configure_unix raise ConfigurationError(msg) __main__.ConfigurationError: Could not run curl-config: [Errno 2] No such file or directory ---------------------------------------- Cleaning up... Command python setup.py egg_info failed with error code 1 in /tmp/pip-build-DuBGJ5/pycurl Storing debug log for failure in /root/.pip/pip.log
在安裝 pyspider 的時候我就遇到了這個問題, pyspider 依賴 pycurl 這個庫,而 pycurl 要求系統中存在相對應的庫。
經過我的測試, curl 是正確安裝了的,但是卻依然提示了找不到 curl-config 的問題
解決方案:
apt-get install libcurl4-gnutls-dev
運行安裝后即可正常安裝 pycurl 。
看完上述內容,是不是對解決Linux下遇到PyCurl的錯誤有進一步的了解,如果還想學習更多內容,歡迎關注億速云行業資訊頻道。
免責聲明:本站發布的內容(圖片、視頻和文字)以原創、轉載和分享為主,文章觀點不代表本網站立場,如果涉及侵權請聯系站長郵箱:is@yisu.com進行舉報,并提供相關證據,一經查實,將立刻刪除涉嫌侵權內容。