2017-02-16 117 views
1

我一直在嘗試在ubuntu 14.04 LTS上安裝加密python-3.4.3。下載libbfi和libssl之後,當我使用pip3來安裝加密時。這是我得到: -加密安裝與pip3

Command /usr/bin/python3 -c "import setuptools, 
tokenize;__file__='/tmp/pip_build_gogol/cryptography/setup.py';exec(compile(getattr(tokenize, 
'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 
'exec'))" install --record /tmp/pip-s1t_s_oy-record/install-record.txt 
--single-version-externally-managed --compile failed with error code 1 in /tmp/pip_build_gogol/cryptography Storing debug log for failure in 
/home/gogol/.pip/pip.log 

如果我再次運行pip3安裝,這就是我所得到的。

[email protected]:~$ pip3 install cryptography 

Traceback (most recent call last): 

    File "/usr/bin/pip3", line 5, in <module> 

    from pkg_resources import load_entry_point 

    File "/usr/local/lib/python3.4/dist-packages/pkg_resources/__init__.py", line 70, in <module> 

    import packaging.version 
ImportError: No module named 'packaging' 

[email protected]:~$ 

請問,任何人都可以幫我嗎?我已經廣泛地查看了關於密碼學的所有答案,但仍然無法做出任何解釋。詳細的答案會非常有幫助。提前致謝。

回答

0

看起來你錯過了作爲依賴項所需的打包模塊。試試:

pip3 install --upgrade pip 

pip3 install packaging 

然後重試安裝加密。