tokyo-python 安装问题

发布于 2024-09-09 18:26:20 字数 4416 浏览 12 评论 0原文

我正在尝试通过 tokyo-python 包在 Python 中使用 Tokyo Cabinet。我已经安装了 Cabinet 和 Cabinet 开发库。然而,每当我尝试使用 pip 或 easy_install 安装 tokyo-python 时,我都会遇到这种丑陋的情况。

matt@amalgam:~/$ bin/pip install tokyo-python
Downloading/unpacking tokyo-python
Downloading tokyo-python-0.6.0.tar.gz (142Kb): 142Kb downloaded
Running setup.py egg_info for package tokyo-python
Installing collected packages: tokyo-python
Running setup.py install for tokyo-python
building 'tokyo.cabinet' extension
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -I/usr/include/python2.6 -c src/cabinet.c -o build/temp.linux-x86_64-2.6/src/cabinet.o
In file included from src/cabinet.c:134:
src/TDB.c: In function ‘TDB_metasearch’:
src/TDB.c:1129: warning: implicit declaration of function ‘tctdbmetasearch’
src/TDB.c:1129: warning: assignment makes pointer from integer without a cast
src/cabinet.c: In function ‘init_cabinet’:
src/cabinet.c:294: error: ‘TDBITTOKEN’ undeclared (first use in this function)
src/cabinet.c:294: error: (Each undeclared identifier is reported only once
src/cabinet.c:294: error: for each function it appears in.)
src/cabinet.c:295: error: ‘TDBITQGRAM’ undeclared (first use in this function)
src/cabinet.c:324: error: ‘TDBQCFTSPH’ undeclared (first use in this function)
src/cabinet.c:325: error: ‘TDBQCFTSAND’ undeclared (first use in this function)
src/cabinet.c:326: error: ‘TDBQCFTSOR’ undeclared (first use in this function)
src/cabinet.c:327: error: ‘TDBQCFTSEX’ undeclared (first use in this function)
src/cabinet.c:331: error: ‘TDBMSUNION’ undeclared (first use in this function)
src/cabinet.c:332: error: ‘TDBMSISECT’ undeclared (first use in this function)
src/cabinet.c:333: error: ‘TDBMSDIFF’ undeclared (first use in this function)
error: command 'gcc' failed with exit status 1
Complete output from command /home/matt/bin/python -c "import setuptools; __file__='/home/matt/build/tokyo-python/setup.py'; execfile('/home/matt/build/tokyo-python/setup.py')" install --single-version-externally-managed --record /tmp/pip-ZqvLvm-record/install-record.txt --install-headers /home/matt/include/site/python2.6:
running install
running build
running build_py
creating build
creating build/lib.linux-x86_64-2.6
creating build/lib.linux-x86_64-2.6/tokyo
copying tokyo/__init__.py -> build/lib.linux-x86_64-2.6/tokyo
copying tokyo/dbm.py -> build/lib.linux-x86_64-2.6/tokyo
running build_ext
building 'tokyo.cabinet' extension
creating build/temp.linux-x86_64-2.6
creating build/temp.linux-x86_64-2.6/src
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -I/usr/include/python2.6 -c src/cabinet.c -o build/temp.linux-x86_64-2.6/src/cabinet.o
In file included from src/cabinet.c:134:
src/TDB.c: In function ‘TDB_metasearch’:
src/TDB.c:1129: warning: implicit declaration of function ‘tctdbmetasearch’
src/TDB.c:1129: warning: assignment makes pointer from integer without a cast
src/cabinet.c: In function ‘init_cabinet’:
src/cabinet.c:294: error: ‘TDBITTOKEN’ undeclared (first use in this function)
src/cabinet.c:294: error: (Each undeclared identifier is reported only once
src/cabinet.c:294: error: for each function it appears in.)
src/cabinet.c:295: error: ‘TDBITQGRAM’ undeclared (first use in this function)
src/cabinet.c:324: error: ‘TDBQCFTSPH’ undeclared (first use in this function)
src/cabinet.c:325: error: ‘TDBQCFTSAND’ undeclared (first use in this function)
src/cabinet.c:326: error: ‘TDBQCFTSOR’ undeclared (first use in this function)
src/cabinet.c:327: error: ‘TDBQCFTSEX’ undeclared (first use in this function)
src/cabinet.c:331: error: ‘TDBMSUNION’ undeclared (first use in this function)
src/cabinet.c:332: error: ‘TDBMSISECT’ undeclared (first use in this function)
src/cabinet.c:333: error: ‘TDBMSDIFF’ undeclared (first use in this function)
error: command 'gcc' failed with exit status 1

Command /home/matt/bin/python -c "import setuptools; __file__='/home/matt/build/tokyo-python/setup.py'; execfile('/home/matt/build/tokyo-python/setup.py')" install --single-version-externally-managed --record /tmp/pip-ZqvLvm-record/install-record.txt --install-headers /home/matt/include/site/python2.6 failed with error code 1
Storing complete log in /home/matt/.pip/pip.log
matt@amalgam:~/$

我能找到的唯一解决方法是从源中删除上述引用,稍微清理一下,并牺牲表支持。如果必须这样做,我就必须这样做,但这太荒谬了,我想以正确的方式去做。

我希望我只是缺少依赖 xyz - 有什么想法吗?

I'm trying to use Tokyo Cabinet in Python via the tokyo-python package. I've installed Cabinet, and the Cabinet development library. However, whenever I try to install tokyo-python with pip or easy_install, I get this ugliness.

matt@amalgam:~/$ bin/pip install tokyo-python
Downloading/unpacking tokyo-python
Downloading tokyo-python-0.6.0.tar.gz (142Kb): 142Kb downloaded
Running setup.py egg_info for package tokyo-python
Installing collected packages: tokyo-python
Running setup.py install for tokyo-python
building 'tokyo.cabinet' extension
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -I/usr/include/python2.6 -c src/cabinet.c -o build/temp.linux-x86_64-2.6/src/cabinet.o
In file included from src/cabinet.c:134:
src/TDB.c: In function ‘TDB_metasearch’:
src/TDB.c:1129: warning: implicit declaration of function ‘tctdbmetasearch’
src/TDB.c:1129: warning: assignment makes pointer from integer without a cast
src/cabinet.c: In function ‘init_cabinet’:
src/cabinet.c:294: error: ‘TDBITTOKEN’ undeclared (first use in this function)
src/cabinet.c:294: error: (Each undeclared identifier is reported only once
src/cabinet.c:294: error: for each function it appears in.)
src/cabinet.c:295: error: ‘TDBITQGRAM’ undeclared (first use in this function)
src/cabinet.c:324: error: ‘TDBQCFTSPH’ undeclared (first use in this function)
src/cabinet.c:325: error: ‘TDBQCFTSAND’ undeclared (first use in this function)
src/cabinet.c:326: error: ‘TDBQCFTSOR’ undeclared (first use in this function)
src/cabinet.c:327: error: ‘TDBQCFTSEX’ undeclared (first use in this function)
src/cabinet.c:331: error: ‘TDBMSUNION’ undeclared (first use in this function)
src/cabinet.c:332: error: ‘TDBMSISECT’ undeclared (first use in this function)
src/cabinet.c:333: error: ‘TDBMSDIFF’ undeclared (first use in this function)
error: command 'gcc' failed with exit status 1
Complete output from command /home/matt/bin/python -c "import setuptools; __file__='/home/matt/build/tokyo-python/setup.py'; execfile('/home/matt/build/tokyo-python/setup.py')" install --single-version-externally-managed --record /tmp/pip-ZqvLvm-record/install-record.txt --install-headers /home/matt/include/site/python2.6:
running install
running build
running build_py
creating build
creating build/lib.linux-x86_64-2.6
creating build/lib.linux-x86_64-2.6/tokyo
copying tokyo/__init__.py -> build/lib.linux-x86_64-2.6/tokyo
copying tokyo/dbm.py -> build/lib.linux-x86_64-2.6/tokyo
running build_ext
building 'tokyo.cabinet' extension
creating build/temp.linux-x86_64-2.6
creating build/temp.linux-x86_64-2.6/src
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -I/usr/include/python2.6 -c src/cabinet.c -o build/temp.linux-x86_64-2.6/src/cabinet.o
In file included from src/cabinet.c:134:
src/TDB.c: In function ‘TDB_metasearch’:
src/TDB.c:1129: warning: implicit declaration of function ‘tctdbmetasearch’
src/TDB.c:1129: warning: assignment makes pointer from integer without a cast
src/cabinet.c: In function ‘init_cabinet’:
src/cabinet.c:294: error: ‘TDBITTOKEN’ undeclared (first use in this function)
src/cabinet.c:294: error: (Each undeclared identifier is reported only once
src/cabinet.c:294: error: for each function it appears in.)
src/cabinet.c:295: error: ‘TDBITQGRAM’ undeclared (first use in this function)
src/cabinet.c:324: error: ‘TDBQCFTSPH’ undeclared (first use in this function)
src/cabinet.c:325: error: ‘TDBQCFTSAND’ undeclared (first use in this function)
src/cabinet.c:326: error: ‘TDBQCFTSOR’ undeclared (first use in this function)
src/cabinet.c:327: error: ‘TDBQCFTSEX’ undeclared (first use in this function)
src/cabinet.c:331: error: ‘TDBMSUNION’ undeclared (first use in this function)
src/cabinet.c:332: error: ‘TDBMSISECT’ undeclared (first use in this function)
src/cabinet.c:333: error: ‘TDBMSDIFF’ undeclared (first use in this function)
error: command 'gcc' failed with exit status 1

Command /home/matt/bin/python -c "import setuptools; __file__='/home/matt/build/tokyo-python/setup.py'; execfile('/home/matt/build/tokyo-python/setup.py')" install --single-version-externally-managed --record /tmp/pip-ZqvLvm-record/install-record.txt --install-headers /home/matt/include/site/python2.6 failed with error code 1
Storing complete log in /home/matt/.pip/pip.log
matt@amalgam:~/$

The only workaround I've been able to find is to to remove the above references from the source, clean it up a bit, and sacrifice table support. If I have to, I have to, but this is ridiculous, and I'd like to do it the right way.

I'm hoping I'm just missing dependency xyz- any ideas?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

笔落惊风雨 2024-09-16 18:26:20

你试过问开发商吗? (虽然我猜这个问题已经过时了,因为当前版本已经是 0.7 了。)

Did you try asking the developer? (Though I guess this question is out of date as current version is already 0.7.)

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文