安装python jnius库期间的问题。(依赖关系?)

安装python jnius库期间的问题。(依赖关系?),python,installation,dependencies,pyjnius,Python,Installation,Dependencies,Pyjnius,我想使用pip为python安装jnius库。我在安装过程中遇到一个错误。下面是发生的事情: C:\Users\Janka\AppData\Local\Programs\Python\Python35-32>python.exe -m pip install jnius Collecting jnius Using cached https://files.pythonhosted.org/packages/45/f5/5673f3906a9e8ca68cb7bc2d9a1eaa944c

我想使用pip为python安装jnius库。我在安装过程中遇到一个错误。下面是发生的事情:

C:\Users\Janka\AppData\Local\Programs\Python\Python35-32>python.exe -m pip 
install jnius
Collecting jnius
Using cached https://files.pythonhosted.org/packages/45/f5/5673f3906a9e8ca68cb7bc2d9a1eaa944c321271c4af621dbb51c13d385a/jnius-1.1.0.tar.gz
Requirement already satisfied: six>=1.7.0 in 
c:\users\janka\appdata\local\programs\python\python35-32\lib\site-packages 
(from jnius) (1.11.0)
Requirement already satisfied: cython in 
c:\users\janka\appdata\local\programs\python\python35-32\lib\site-packages 
(from jnius) (0.28.3)
Building wheels for collected packages: jnius
我无法解决的第一个错误: 可能,我没有setup.py文件。我可以通过pip安装它吗?或者我该怎么办?maybee我确实有,如果有,我在哪里可以找到它或者如何检查它

Running setup.py bdist_wheel for jnius ... error
Complete output from command 
C:\Users\Janka\AppData\Local\Programs\Python\Python35-32\python.exe -u -c 
"import setuptools, 
tokenize;__file__='C:\\Users\\Janka\\AppData\\Local\\Temp\\pip-install- 
pnoxk945\\jnius\\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 C:\Users\Janka\AppData\Local\Temp\pip- 
wheel-ngvrr7r6 --python-tag cp35:
WARNING: Not able to assign machine() = AMD64 to a cpu value!
(好吧,windows没有放弃:D)

我需要微软Visual C++ 14,我尝试了建议链接,但是网页上写着“过期帐号”< /P> 同样,setup.py文件

Running setup.py install for jnius ... error
Complete output from command 
C:\Users\Janka\AppData\Local\Programs\Python\Python35-32\python.exe -u -c 
"import setuptools, 
tokenize;__file__='C:\\Users\\Janka\\AppData\\Local\\Temp\\pip-install- 
pnoxk945\\jnius\\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\Janka\AppData\Local\Temp\pip- 
record-rdnylq3b\install-record.txt --single-version-externally-managed -- 
compile:
WARNING: Not able to assign machine() = AMD64 to a cpu value!
         Using cpu = 'i386' instead!
running install
running build
running build_py
creating build
creating build\lib.win32-3.5
copying jnius_config.py -> build\lib.win32-3.5
creating build\lib.win32-3.5\jnius
copying jnius\reflect.py -> build\lib.win32-3.5\jnius
copying jnius\signatures.py -> build\lib.win32-3.5\jnius
copying jnius\__init__.py -> build\lib.win32-3.5\jnius
running build_ext
skipping 'jnius\jnius.c' Cython extension (up-to-date)
building 'jnius' extension
错误:微软Visual C++ 14是必需的——我在哪里可以得到它?如何安装它

error: Microsoft Visual C++ 14.0 is required. Get it with "Microsoft Visual 
C++ Build Tools": http://landinghub.visualstudio.com/visual-cpp-build-tools

----------------------------------------
Command "C:\Users\Janka\AppData\Local\Programs\Python\Python35-32\python.exe 
-u -c "import setuptools, 
tokenize;__file__='C:\\Users\\Janka\\AppData\\Local\\Temp\\pip-install- 
pnoxk945\\jnius\\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\Janka\AppData\Local\Temp\pip- 
record-rdnylq3b\install-record.txt --single-version-externally-managed -- 
compile" failed with error code 1 in C:\Users\Janka\AppData\Local\Temp\pip- 
install-pnoxk945\jnius\

C:\Users\Janka\AppData\Local\Programs\Python\Python35-32>

(我使用的是windows 10)

您需要安装Visual Studio 2015。在安装期间,勾选<代码>语言的方框> > C++ > <代码> 此外,您可能需要设置环境变量

GYP_MSVS_VERSION = 2015
P>可选的,你可以下载Python 2.7的C++编译器

有关安装的更多详细信息,请参见此处

如果我安装了Visual Studio 2017会怎么样?它不也是兼容的吗?那么jnius运行错误的setup.py bdist_wheel呢?如果我确实有这个文件,我应该在哪里查找?如果我没有(我想我没有),我怎么能得到它?它应该工作得很好。你得自己试一下。或者,您可以使用下面的链接的C++编译器。根据Jnius的文档,这应该可以正常工作。好的,我如何在windows中为非管理员用户设置环境变量?我发现了这个,但我不知道如何使用它。我知道它在没有设置变量的情况下也能工作:)。谢谢你的建议。
error: Microsoft Visual C++ 14.0 is required. Get it with "Microsoft Visual 
C++ Build Tools": http://landinghub.visualstudio.com/visual-cpp-build-tools

----------------------------------------
Command "C:\Users\Janka\AppData\Local\Programs\Python\Python35-32\python.exe 
-u -c "import setuptools, 
tokenize;__file__='C:\\Users\\Janka\\AppData\\Local\\Temp\\pip-install- 
pnoxk945\\jnius\\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\Janka\AppData\Local\Temp\pip- 
record-rdnylq3b\install-record.txt --single-version-externally-managed -- 
compile" failed with error code 1 in C:\Users\Janka\AppData\Local\Temp\pip- 
install-pnoxk945\jnius\

C:\Users\Janka\AppData\Local\Programs\Python\Python35-32>
GYP_MSVS_VERSION = 2015