无法针对RocksDB主服务器安装pyrocksdb

时间:2015-04-04 16:59:25

标签: rocksdb

我按照此处的说明操作:http://pyrocksdb.readthedocs.org/en/latest/installation.html

当我尝试pip install git+git://github.com/stephan-hof/pyrocksdb.git时,出现以下错误输出:

running install

running build

running build_py

creating build

creating build/lib.linux-x86_64-3.4

creating build/lib.linux-x86_64-3.4/rocksdb

copying rocksdb/__init__.py -> build/lib.linux-x86_64-3.4/rocksdb

copying rocksdb/interfaces.py -> build/lib.linux-x86_64-3.4/rocksdb

copying rocksdb/errors.py -> build/lib.linux-x86_64-3.4/rocksdb

creating build/lib.linux-x86_64-3.4/rocksdb/tests

copying rocksdb/tests/__init__.py -> build/lib.linux-x86_64-3.4/rocksdb/tests

copying rocksdb/tests/test_db.py -> build/lib.linux-x86_64-3.4/rocksdb/tests

copying rocksdb/tests/test_options.py -> build/lib.linux-x86_64-3.4/rocksdb/tests

running egg_info

creating pyrocksdb.egg-info

writing dependency_links to pyrocksdb.egg-info/dependency_links.txt

writing top-level names to pyrocksdb.egg-info/top_level.txt

writing requirements to pyrocksdb.egg-info/requires.txt

writing pyrocksdb.egg-info/PKG-INFO

writing manifest file 'pyrocksdb.egg-info/SOURCES.txt'

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



reading manifest file 'pyrocksdb.egg-info/SOURCES.txt'

writing manifest file 'pyrocksdb.egg-info/SOURCES.txt'

copying rocksdb/_rocksdb.cpp -> build/lib.linux-x86_64-3.4/rocksdb

running build_ext

building 'rocksdb._rocksdb' extension

creating build/temp.linux-x86_64-3.4

creating build/temp.linux-x86_64-3.4/rocksdb

x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -g -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -D_FORTIFY_SOURCE=2 -fPIC -I/home/iulian/py3env/include -I/usr/include/python3.4m -c rocksdb/_rocksdb.cpp -o build/temp.linux-x86_64-3.4/rocksdb/_rocksdb.o -std=gnu++11 -O3 -Wall -Wextra -Wconversion -fno-strict-aliasing

cc1plus: warning: command line option ‘-Wstrict-prototypes’ is valid for C/ObjC but not for C++ [enabled by default]

rocksdb/_rocksdb.cpp:289:27: fatal error: rocksdb/slice.h: No such file or directory

 #include "rocksdb/slice.h"

                           ^

compilation terminated.

error: command 'x86_64-linux-gnu-gcc' failed with exit status 1

----------------------------------------
Command "/home/iulian/py3env/bin/python -c "import setuptools, tokenize;__file__='/tmp/pip-mndoekm3-build/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-3fwa2_ff-record/install-record.txt --single-version-externally-managed --compile --install-headers /home/iulian/py3env/include/site/python3.4" failed with error code 1 in /tmp/pip-mndoekm3-build

我试图检查各种版本的RocksDB(3.5,3.6,3.8,3.9)但仍然没有运气。

我在64位Ubuntu 14.04上使用Python 3.4。

1 个答案:

答案 0 :(得分:2)

您必须检查是否已安装Cython == 0.20!我遇到了同样的问题并解决了它!