首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >Cygwin:(python)错误:构建加密轮子失败

Cygwin:(python)错误:构建加密轮子失败
EN

Stack Overflow用户
提问于 2021-07-19 18:07:09
回答 1查看 240关注 0票数 0

我正在使用cygwin开发一个django应用程序。而我却被一个名为digikey api的软件包安装所困。它需要安装一个加密包,并且会失败,并显示以下错误消息:

代码语言:javascript
复制
generating cffi module 'build/temp.cygwin-3.2.0-x86_64-3.8/_openssl.c'
running build_rust

    =============================DEBUG ASSISTANCE=============================
    If you are seeing a compilation error please try the following steps to
    successfully install cryptography:
    1) Upgrade to the latest pip and try again. This will fix errors for most
       users. See: https://pip.pypa.io/en/stable/installing/#upgrading-pip
    2) Read https://cryptography.io/en/latest/installation.html for specific
       instructions for your platform.
    3) Check our frequently asked questions for more information:
       https://cryptography.io/en/latest/faq.html
    4) Ensure you have a recent Rust toolchain installed:
       https://cryptography.io/en/latest/installation.html#rust
    5) If you are experiencing issues with Rust for *this release only* you may
       set the environment variable `CRYPTOGRAPHY_DONT_BUILD_RUST=1`.
    =============================DEBUG ASSISTANCE=============================

error: can't find Rust compiler

If you are using an outdated pip version, it is possible a prebuilt wheel is available for this package but pip is not able to install from it. Installing from the wheel would avoid the need for a Rust compiler.

To update pip, run:

    pip install --upgrade pip

and then retry package installation.

If you did intend to build this package from source, try installing a Rust compiler from your system package manager and ensure it is on the PATH during installation. Alternatively, rustup (available at https://rustup.rs) is the recommended way to download and update the Rust compiler toolchain.

This package requires Rust >=1.41.0.
----------------------------------------
ERROR: Failed building wheel for cryptography
Failed to build cryptography
ERROR: Could not build wheels for cryptography which use PEP 517 and cannot be installed directly
(venv)

我已经尝试了各种解决方案,但到目前为止还没有成功。pip install --升级pip没有解决问题)。有趣的是,它在这个python虚拟环境中失败了。但是它在这个环境之外是成功的(相同的python版本3.8.10)。

感谢你帮我解决这个问题。塞巴斯蒂安

EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2021-07-20 15:53:21

这个信息非常明确。

代码语言:javascript
复制
error: can't find Rust compiler

由于Cygwin没有rust编译器,因此您无法构建它

https://cygwin.com/packages/package_list.html

票数 1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/68438667

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档