为 Python3 安装 Charm-Crypto 时出现问题



各位程序员大家好,目前我正在尝试在我的 Ubuntu 上安装 Charm-Crypto 0.43。不幸的是,似乎没有任何效果。我尝试了链接的手动安装,以及pip install charm-crypto

我总是收到此错误日志:

[...]
running build_ext
    building 'charm.core.math.pairing' extension
    creating build/temp.linux-x86_64-3.6
    creating build/temp.linux-x86_64-3.6/charm
    creating build/temp.linux-x86_64-3.6/charm/core
    creating build/temp.linux-x86_64-3.6/charm/core/math
    creating build/temp.linux-x86_64-3.6/charm/core/math/pairing
    creating build/temp.linux-x86_64-3.6/charm/core/utilities
    creating build/temp.linux-x86_64-3.6/charm/core/benchmark
    x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -g -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -DBENCHMARK_ENABLED=1 -Icharm/core/utilities/ -Icharm/core/benchmark/ -I/usr/include/python3.6m -I/home/debbi/Documents/env/01_chainmed/include/python3.6m -c charm/core/math/pairing/pairingmodule.c -o build/temp.linux-x86_64-3.6/charm/core/math/pairing/pairingmodule.o
    In file included from charm/core/math/pairing/pairingmodule.c:30:0:
    charm/core/math/pairing/pairingmodule.h:38:10: fatal error: pbc/pbc.h: No such file or directory
     #include <pbc/pbc.h>
              ^~~~~~~~~~~
    compilation terminated.
    error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
    ----------------------------------------
Command "/home/debbi/Documents/env/01_chainmed/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-wfcawqbr/charm-crypto/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('rn', 'n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-record-pfeoo7we/install-record.txt --single-version-externally-managed --compile --install-headers /home/debbi/Documents/env/01_chainmed/include/site/python3.6/charm-crypto" failed with error code 1 in /tmp/pip-install-wfcawqbr/charm-crypto/

我尝试了所有建议的python-dev和libssl等安装。我可以通过谷歌搜索找到(这个,这个,这个,这个只是为了命名一个视图)。我还尝试使用 python2.7 和 3.6 安装它,不幸的是,没有任何效果对我有用。

也许有人知道这个问题?

提前感谢您抽出宝贵时间。

有这个网站: http://pages.cs.wisc.edu/~ace/install-charm.html只需按照说明进行操作,但对我来说,我必须手动检查 Charm-0.50 开发分支,然后安装此版本。

最新更新