私はpipを使用してmonary pythonパッケージをインストールしようとしています。私は、コマンドを実行するとmonitorをインストールする際のエラーpip
pip install monary
は、これは私がMSのVisual Studioをアンインストールし、再インストールしようとしましたが、私はfailed with exit status 2
が正確に何を意味するのか分からない、と私はないんだけど、フル出力
C:\Users\krist>pip install monary
Collecting monary
Using cached Monary-0.5.0.tar.gz
Requirement already satisfied: pymongo in c:\users\krist\anaconda3\lib\site-packages (from monary)
Requirement already satisfied: numpy in c:\users\krist\anaconda3\lib\site-packages (from monary)
Building wheels for collected packages: monary
Running setup.py bdist_wheel for monary ... error
Complete output from command c:\users\krist\anaconda3\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\krist\\AppData\\Local\\Temp\\pip-build-xkxevy62\\monary\\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\krist\AppData\Local\Temp\tmp2hws0x_vpip-wheel- --python-tag cp35:
C:\Users\krist\AppData\Local\Temp\pip-build-xkxevy62\monary\setup.py:90:
UserWarning: WARNING: the python package pkgconfig is not installed. If you
have pkg-config installed on your system, please install the python's pkgconfig, e.g. "pip install pkgconfig". Will use libmongoc=C:/Program Files\libmongoc and libbson=C:/Program Files\libbson instead.
% (mongoc_src, bson_src)))
running bdist_wheel
running build
running build_py
creating build
creating build\lib.win-amd64-3.5
creating build\lib.win-amd64-3.5\monary
copying monary\datehelper.py -> build\lib.win-amd64-3.5\monary
copying monary\monary.py -> build\lib.win-amd64-3.5\monary
copying monary\monary_param.py -> build\lib.win-amd64-3.5\monary
copying monary\ordereddict.py -> build\lib.win-amd64-3.5\monary
copying monary\write_concern.py -> build\lib.win-amd64-3.5\monary
copying monary\__init__.py -> build\lib.win-amd64-3.5\monary
running build_ext
building 'monary.libcmonary' extension
creating build\temp.win-amd64-3.5
creating build\temp.win-amd64-3.5\Release
creating build\temp.win-amd64-3.5\Release\monary
C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\BIN\x86_amd64\cl.exe /c /nologo /Ox /W3 /GL /DNDEBUG /MD "-IC:/Program Files\libmongoc\include\libmongoc-1.0" "-IC:/Program Files\libbson\include\libbson-1.0" -Ic:\users\krist\anaconda3\include -Ic:\users\krist\anaconda3\include "-IC:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\INCLUDE" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.14393.0\ucrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.14393.0\shared" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.14393.0\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.14393.0\winrt" /Tcmonary\cmonary.c /Fobuild\temp.win-amd64-3.5\Release\monary\cmonary.obj -fPIC -O2 -DNDEBUG
cl : Command line warning D9002 : ignoring unknown option '-fPIC'
cmonary.c
monary\cmonary.c(8): fatal error C1083: Cannot open include file: 'mongoc.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
----------------------------------------
Failed building wheel for monary
Running setup.py clean for monary
Failed to build monary
Installing collected packages: monary
Running setup.py install for monary ... error
Complete output from command c:\users\krist\anaconda3\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\krist\\AppData\\Local\\Temp\\pip-build-xkxevy62\\monary\\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\krist\AppData\Local\Temp\pip-9enpcfz5-record\install-record.txt --single-version-externally-managed --compile:
C:\Users\krist\AppData\Local\Temp\pip-build-xkxevy62\monary\setup.py:90: UserWarning: WARNING: the python package pkgconfig is not installed. If you have pkg-config installed on your system, please install the python's pkgconfig, e.g. "pip install pkgconfig". Will use libmongoc=C:/Program Files\libmongoc and libbson=C:/Program Files\libbson instead.
% (mongoc_src, bson_src)))
running install
running build
running build_py
creating build
creating build\lib.win-amd64-3.5
creating build\lib.win-amd64-3.5\monary
copying monary\datehelper.py -> build\lib.win-amd64-3.5\monary
copying monary\monary.py -> build\lib.win-amd64-3.5\monary
copying monary\monary_param.py -> build\lib.win-amd64-3.5\monary
copying monary\ordereddict.py -> build\lib.win-amd64-3.5\monary
copying monary\write_concern.py -> build\lib.win-amd64-3.5\monary
copying monary\__init__.py -> build\lib.win-amd64-3.5\monary
running build_ext
building 'monary.libcmonary' extension
creating build\temp.win-amd64-3.5
creating build\temp.win-amd64-3.5\Release
creating build\temp.win-amd64-3.5\Release\monary
C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\BIN\x86_amd64\cl.exe /c /nologo /Ox /W3 /GL /DNDEBUG /MD "-IC:/Program Files\libmongoc\include\libmongoc-1.0" "-IC:/Program Files\libbson\include\libbson-1.0" -Ic:\users\krist\anaconda3\include -Ic:\users\krist\anaconda3\include "-IC:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\INCLUDE" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.14393.0\ucrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.14393.0\shared" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.14393.0\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.14393.0\winrt" /Tcmonary\cmonary.c /Fobuild\temp.win-amd64-3.5\Release\monary\cmonary.obj -fPIC -O2 -DNDEBUG
cl : Command line warning D9002 : ignoring unknown option '-fPIC'
cmonary.c
monary\cmonary.c(8): fatal error C1083: Cannot open include file: 'mongoc.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:\users\krist\anaconda3\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\krist\\AppData\\Local\\Temp\\pip-build-xkxevy62\\monary\\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\krist\AppData\Local\Temp\pip-9enpcfz5-record\install-record.txt --single-version-externally-managed --compile" failed with error code 1 in C:\Users\krist\AppData\Local\Temp\pip-build-xkxevy62\monary\
ですエラーを修正するにはどうすればいいですか:
monary\cmonary.c(8): fatal error C1083: Cannot open include file: 'mongoc.h': No such file or directory
このパッケージをダウンロードするには、何が必要ですか?
更新:私はpkgconfig
をインストールするには、警告に気づき、ということでしたが、最終的な結果は変更されません - まだ終わりでエラーに同じを得る:
monary\cmonary.c(8): fatal error C1083: Cannot open include file: 'mongoc.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:\users\krist\anaconda3\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\krist\\AppData\\Local\\Temp\\pip-build-xkxevy62\\monary\\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\krist\AppData\Local\Temp\pip-9enpcfz5-record\install-record.txt --single-version-externally-managed --compile" failed with error code 1 in C:\Users\krist\AppData\Local\Temp\pip-build-xkxevy62\monary\
デフォルトのインストール手順に従ってmongo cドライバをインストールすると、C:/ mongo-c-driver(http://mongoc.org/libmongoc/current/installing.html)ディレクトリに保存されました。それを見つけるにはpkgconfigのlibmongocに名前を変更する必要がありますか? – boop
いいえ、指示に従って、すべての依存関係をインストールするだけでうまくいくはずです。 –
何らかの理由でpkg-configが動作しなくなってしまいましたが、デフォルトのディレクトリを渡すことはやりました。ありがとう! – boop