简体   繁体   English

Anaconda Python:HiveServer2的客户端驱动程序无法安装

[英]Anaconda Python: client driver for HiveServer2 fails to install

I get this error when trying to install pyhs2 on Windows 7 64-bit. 尝试在Windows 7 64位上安装pyhs2时出现此错误。 I'm using CMD.exe to install the package, even though I'm not quite a big fan of it. 我正在使用CMD.exe安装该软件包,即使我不太喜欢它。 I've downloaded the package from this link and placed in my Download directory. 我已经从此链接下载了软件包,并将其放置在我的下载目录中。

I'm currently using Conda 3.7.3 我目前正在使用Conda 3.7.3

C:\Users\gianluca.rossi>pip install C:\Users\gianluca.rossi\Downloads\pyhs2-0.6.
0.tar.gz
Unpacking c:\users\gianluca.rossi\downloads\pyhs2-0.6.0.tar.gz
  Running setup.py (path:c:\users\gianlu~1.ros\appdata\local\temp\pip-0ukipa-bui
ld\setup.py) egg_info for package from file:///C:/Users/gianluca.rossi/Downloads
/pyhs2-0.6.0.tar.gz

    warning: no files found matching 'ChangeLog'
    warning: no files found matching 'MakeFile'
    warning: no previously-included files matching '*.pyc' found anywhere in dis
tribution
    warning: no previously-included files matching '.gitignore' found anywhere i
n distribution
    warning: no previously-included files matching '.DS_Store' found anywhere in
 distribution
Downloading/unpacking sasl (from pyhs2==0.6.0)
  Downloading sasl-0.1.3.tar.gz
  Running setup.py (path:c:\users\gianlu~1.ros\appdata\local\temp\pip_build_gian
luca.rossi\sasl\setup.py) egg_info for package sasl

Requirement already satisfied (use --upgrade to upgrade): thrift in c:\users\gia
nluca.rossi\appdata\local\continuum\anaconda\lib\site-packages\thrift-0.9.1-py2.
7.egg (from pyhs2==0.6.0)
Installing collected packages: sasl, pyhs2
  Running setup.py install for sasl

    building '_saslwrapper' extension
    C:\Users\gianluca.rossi\AppData\Local\Continuum\Anaconda\Scripts\gcc.bat -DM
S_WIN64 -mdll -O -Wall -Isasl -IC:\Users\gianluca.rossi\AppData\Local\Continuum\
Anaconda\include -IC:\Users\gianluca.rossi\AppData\Local\Continuum\Anaconda\PC -
c sasl/saslwrapper.cpp -o build\temp.win-amd64-2.7\Release\sasl\saslwrapper.o
    sasl/saslwrapper.cpp:21:23: fatal error: sasl/sasl.h: No such file or direct
ory
    compilation terminated.
    error: command 'gcc' failed with exit status 1
    Complete output from command C:\Users\gianluca.rossi\AppData\Local\Continuum
\Anaconda\python.exe -c "import setuptools, tokenize;__file__='c:\\users\\gianlu
~1.ros\\appdata\\local\\temp\\pip_build_gianluca.rossi\\sasl\\setup.py';exec(com
pile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __f
ile__, 'exec'))" install --record c:\users\gianlu~1.ros\appdata\local\temp\pip-s
qckja-record\install-record.txt --single-version-externally-managed --compile:
    running install

running build

running build_py

creating build

creating build\lib.win-amd64-2.7

creating build\lib.win-amd64-2.7\sasl

copying sasl\__init__.py -> build\lib.win-amd64-2.7\sasl

copying sasl\saslwrapper.py -> build\lib.win-amd64-2.7\sasl

running egg_info

writing sasl.egg-info\PKG-INFO

writing top-level names to sasl.egg-info\top_level.txt

writing dependency_links to sasl.egg-info\dependency_links.txt

warning: manifest_maker: standard file '-c' not found



reading manifest file 'sasl.egg-info\SOURCES.txt'

reading manifest template 'MANIFEST.in'

writing manifest file 'sasl.egg-info\SOURCES.txt'

running build_ext

building '_saslwrapper' extension

creating build\temp.win-amd64-2.7

creating build\temp.win-amd64-2.7\Release

creating build\temp.win-amd64-2.7\Release\sasl

C:\Users\gianluca.rossi\AppData\Local\Continuum\Anaconda\Scripts\gcc.bat -DMS_WI
N64 -mdll -O -Wall -Isasl -IC:\Users\gianluca.rossi\AppData\Local\Continuum\Anac
onda\include -IC:\Users\gianluca.rossi\AppData\Local\Continuum\Anaconda\PC -c sa
sl/saslwrapper.cpp -o build\temp.win-amd64-2.7\Release\sasl\saslwrapper.o

sasl/saslwrapper.cpp:21:23: fatal error: sasl/sasl.h: No such file or directory

compilation terminated.

error: command 'gcc' failed with exit status 1

----------------------------------------
Cleaning up...
Command C:\Users\gianluca.rossi\AppData\Local\Continuum\Anaconda\python.exe -c "
import setuptools, tokenize;__file__='c:\\users\\gianlu~1.ros\\appdata\\local\\t
emp\\pip_build_gianluca.rossi\\sasl\\setup.py';exec(compile(getattr(tokenize, 'o
pen', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install
--record c:\users\gianlu~1.ros\appdata\local\temp\pip-sqckja-record\install-reco
rd.txt --single-version-externally-managed --compile failed with error code 1 in
 c:\users\gianlu~1.ros\appdata\local\temp\pip_build_gianluca.rossi\sasl
Storing debug log for failure in C:\Users\gianluca.rossi\pip\pip.log

From the error message I understood the issue is that there is no 'sasl/sasl.h' directory, so I assume this is a package I have to install manually. 从错误消息中我了解到问题是没有'sasl / sasl.h'目录,因此我认为这是一个必须手动安装的软件包。 Unfortunately I see the same error message when trying to install 'sasl'. 不幸的是,当我尝试安装'sasl'时看到相同的错误消息。

$ pip install sasl-0.1.3.tar.gz
Unpacking c:\users\gianluca.rossi\downloads\sasl-0.1.3.tar.gz
  Running setup.py (path:c:\cygwin64\tmp\pip-qkq_jo-build\setup.py) egg_info for package from file:///C:/Users/gianluca.rossi/Downloads/sasl-0.1.3.tar.gz

Installing collected packages: sasl
  Running setup.py install for sasl

    building '_saslwrapper' extension
    C:\Users\gianluca.rossi\AppData\Local\Continuum\Anaconda\Scripts\gcc.bat -DMS_WIN64 -mdll -O -Wall -Isasl -IC:\Users\gianluca.rossi\AppData\Local\Continuum\Anaconda\include -IC:\Users\gianluca.rossi\AppData\Local\Continuum\Anaconda\PC -c sasl/saslwrapper.cpp -o build\temp.win-amd64-2.7\Release\sasl\saslwrapper.o
    sasl/saslwrapper.cpp:21:23: fatal error: sasl/sasl.h: No such file or directory
    compilation terminated.
    error: command 'gcc' failed with exit status 1
    Complete output from command C:\Users\gianluca.rossi\AppData\Local\Continuum\Anaconda\python.exe -c "import setuptools, tokenize;__file__='c:\\cygwin64\\tmp\\pip-qkq_jo-build\\setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record c:\cygwin64\tmp\pip-ogzt6q-record\install-record.txt --single-version-externally-managed --compile:
    running install

running build

running build_py

creating build

creating build\lib.win-amd64-2.7

creating build\lib.win-amd64-2.7\sasl

copying sasl\__init__.py -> build\lib.win-amd64-2.7\sasl

copying sasl\saslwrapper.py -> build\lib.win-amd64-2.7\sasl

running egg_info

writing sasl.egg-info\PKG-INFO

writing top-level names to sasl.egg-info\top_level.txt

writing dependency_links to sasl.egg-info\dependency_links.txt

warning: manifest_maker: standard file '-c' not found



reading manifest file 'sasl.egg-info\SOURCES.txt'

reading manifest template 'MANIFEST.in'

writing manifest file 'sasl.egg-info\SOURCES.txt'

running build_ext

building '_saslwrapper' extension

creating build\temp.win-amd64-2.7

creating build\temp.win-amd64-2.7\Release

creating build\temp.win-amd64-2.7\Release\sasl

C:\Users\gianluca.rossi\AppData\Local\Continuum\Anaconda\Scripts\gcc.bat -DMS_WIN64 -mdll -O -Wall -Isasl -IC:\Users\gianluca.rossi\AppData\Local\Continuum\Anaconda\include -IC:\Users\gianluca.rossi\AppData\Local\Continuum\Anaconda\PC -c sasl/saslwrapper.cpp -o build\temp.win-amd64-2.7\Release\sasl\saslwrapper.o

sasl/saslwrapper.cpp:21:23: fatal error: sasl/sasl.h: No such file or directory

compilation terminated.

error: command 'gcc' failed with exit status 1

----------------------------------------
Cleaning up...
Command C:\Users\gianluca.rossi\AppData\Local\Continuum\Anaconda\python.exe -c "import setuptools, tokenize;__file__='c:\\cygwin64\\tmp\\pip-qkq_jo-build\\setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record c:\cygwin64\tmp\pip-ogzt6q-record\install-record.txt --single-version-externally-managed --compile failed with error code 1 in c:\cygwin64\tmp\pip-qkq_jo-build
Storing debug log for failure in C:\cygwin64\home\gianluca.rossi\pip\pip.log

The sasl library is Python bindings to the sasl C library. sasl库是Python与sasl C库的绑定。 To pip install it (or install from source), you'll need to have the sasl C library installed first, so that it can find the header files. 要点安装(或从源代码安装),您需要先安装sasl C库,以便它可以找到头文件。

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

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