错误信息如下:

Collecting pycrypto
  Using cached pycrypto-2.6.1.tar.gz (446 kB)
  Preparing metadata (setup.py) ... done
Building wheels for collected packages: pycrypto
  Building wheel for pycrypto (setup.py) ... error
  error: subprocess-exited-with-error

× python setup.py bdist_wheel did not run successfully.
  │ exit code: 1
  ╰─> [183 lines of output]
      running bdist_wheel

..........

winrand.c
      D:\Windows Kits\10\include\10.0.19041.0\ucrt\inttypes.h(31): error C2061: 语法错误: 标识符“intmax_t”
      D:\Windows Kits\10\include\10.0.19041.0\ucrt\inttypes.h(32): error C2061: 语法错误: 标识符“rem”
      D:\Windows Kits\10\include\10.0.19041.0\ucrt\inttypes.h(32): error C2059: 语法错误:“;”
      D:\Windows Kits\10\include\10.0.19041.0\ucrt\inttypes.h(33): error C2059: 语法错误:“}”
      D:\Windows Kits\10\include\10.0.19041.0\ucrt\inttypes.h(35): error C2061: 语法错误: 标识符“imaxdiv_t”
      D:\Windows Kits\10\include\10.0.19041.0\ucrt\inttypes.h(35): error C2059: 语法错误:“;”
      D:\Windows Kits\10\include\10.0.19041.0\ucrt\inttypes.h(45): error C2143: 语法错误: 缺少“{”(在“__cdecl”的前面)
      D:\Windows Kits\10\include\10.0.19041.0\ucrt\inttypes.h(46): error C2146: 语法错误: 缺少“)”(在标识符“_Number” 的前面)
      D:\Windows Kits\10\include\10.0.19041.0\ucrt\inttypes.h(46): error C2061: 语法错误: 标识符“_Number”
      D:\Windows Kits\10\include\10.0.19041.0\ucrt\inttypes.h(46): error C2059: 语法错误:“;”
      D:\Windows Kits\10\include\10.0.19041.0\ucrt\inttypes.h(47): error C2059: 语法错误:“)”
      D:\Windows Kits\10\include\10.0.19041.0\ucrt\inttypes.h(50): error C2143: 语法错误: 缺少“{”(在“__cdecl”的前面)
      D:\Windows Kits\10\include\10.0.19041.0\ucrt\inttypes.h(51): error C2146: 语法错误: 缺少“)”(在标识符“_Numerator”的前面)
      D:\Windows Kits\10\include\10.0.19041.0\ucrt\inttypes.h(51): error C2061: 语法错误: 标识符“_Numerator”
      D:\Windows Kits\10\include\10.0.19041.0\ucrt\inttypes.h(51): error C2059: 语法错误:“;”
      D:\Windows Kits\10\include\10.0.19041.0\ucrt\inttypes.h(51): error C2059: 语法错误:“,”
      D:\Windows Kits\10\include\10.0.19041.0\ucrt\inttypes.h(53): error C2059: 语法错误:“)”
      D:\Windows Kits\10\include\10.0.19041.0\ucrt\inttypes.h(55): error C2143: 语法错误: 缺少“{”(在“__cdecl”的前面)
      D:\Windows Kits\10\include\10.0.19041.0\ucrt\inttypes.h(61): error C2143: 语法错误: 缺少“{”(在“__cdecl”的前面)
      D:\Windows Kits\10\include\10.0.19041.0\ucrt\inttypes.h(68): error C2143: 语法错误: 缺少“{”(在“__cdecl”的前面)
      D:\Windows Kits\10\include\10.0.19041.0\ucrt\inttypes.h(74): error C2143: 语法错误: 缺少“{”(在“__cdecl”的前面)
      D:\Windows Kits\10\include\10.0.19041.0\ucrt\inttypes.h(81): error C2143: 语法错误: 缺少“{”(在“__cdecl”的前面)
      D:\Windows Kits\10\include\10.0.19041.0\ucrt\inttypes.h(87): error C2143: 语法错误: 缺少“{”(在“__cdecl”的前面)
      D:\Windows Kits\10\include\10.0.19041.0\ucrt\inttypes.h(94): error C2143: 语法错误: 缺少“{”(在“__cdecl”的前面)
      D:\Windows Kits\10\include\10.0.19041.0\ucrt\inttypes.h(100): error C2143: 语法错误: 缺少“{”(在“__cdecl”的前面)
      error: command 'D:\\Program Files (x86)\\Microsoft Visual Studio\\2019\\Community\\VC\\Tools\\MSVC\\14.29.30037\\bin\\HostX86\\x64\\cl.exe' failed with exit code 2
      [end of output]

note: This error originates from a subprocess, and is likely not a problem with pip.
  ERROR: Failed building wheel for pycrypto
  Running setup.py clean for pycrypto
Failed to build pycrypto
Installing collected packages: pycrypto
  Running setup.py install for pycrypto ... error
  error: subprocess-exited-with-error

解决方法:

将Microsoft Visual Studio安装目录(D:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.29.30037\include)下的stdint.h文件复制到

D:\Windows Kits\10\Include\10.0.19041.0\ucrt

并将D:\Windows Kits\10\Include\10.0.19041.0\ucrt目录下的inttypes.h下的尖括号改成双引号(引号是引用非标准库的头文件,编译器从用户的工作目录开始搜索)

然后重新安装:pip install pycrypto

Windows 10 下安装pycrypto时出错的解决问题相关推荐

  1. python3.5安装pillow_Python3.5在Windows 10上安装Pillow时出错

    当尝试在运行Python 3.5的Windows 10计算机上使用easy\u installer安装Pillow时:C:\Users\MMG\AppData\Local\Programs\Pytho ...

  2. python安装环境变量出错_在windows 10上安装twisted时出错。INCLUDE环境变量为空

    我已经在我的windows机器上安装了python3.4.4,并试图在我的机器上安装twisted库.在>>>python Python 3.4.4 (v3.4.4:737efcad ...

  3. 关于 Windows 10 下安装 Linux 过程及报 'WSL...' 错误的解决办法

    今天下午在群里看到有朋友发有关"Windows 10 下按安装 Linux 系统"的消息,小白我很是激动啊(Linux 贴近工作,Windows 贴近生活,割舍不下-),虽然可以在 ...

  4. (一) windows 10 下安装 mongodb 并 globalsign/mgo 包的简单使用

    文章目录 windows 下安装 小坑 运行 mongodb 服务器 连接 mongodb 使用 globalsign/mgo 操作 mongodb windows 下安装 在 windows 下安装 ...

  5. windows 10下安装kali linux 双系统教程

    由于本人先安装了windows10,所以将硬盘划分一个区安装kali 准备工作: 1. 下载kali镜像:官网下载链接 2. 用win32DiskImager制作启动盘 :打开度盘下载链接(注:用ul ...

  6. Windows 10下安装scrapy(pip方式,非wheel)

    1.安装Microsoft Visual Studio Build Tools 打开下载链接,点击"https://aka.ms/BuildTools",跳转后再页面底部找到&qu ...

  7. 目标检测第1步:如何在Windows 10下安装MiniConda?

    (请先看置顶博文)本博打开方式!!!请详读!!!请详读!!!请详读!!!_Cat-CSDN博客 目录 一.Conda是什么? 二.Anaconda和MiniConda的区别是什么? 三.如何安装Min ...

  8. Windows 10下安装Elementary OS双系统

    本文毫无技术含量,望周知,勿喷.写这篇教程仅仅是为了记录下安装双系统的过程,方便以后折腾. 长期使用Windows操作系统总会带来审美疲劳或者累觉不爱,那么Linux就是一个新大陆.Elementar ...

  9. Windows 10 下安装Ubuntu子系统 编译Android源码问题记录

    一.Ubuntu子系统安装 1.启用WSL Windows Subsystem for Linux(简称WSL)是一个在Windows 10\11上能够运行原生Linux二进制可执行文件(ELF格式) ...

最新文章

  1. DPU(Data Processing Unit)数据处理器
  2. 神经网络设计与分析之sin函数拟合分析
  3. 网络营销外包——网络营销外包公司表示网站更新仅仅是原创还不够
  4. ivona tts语音合成引擎_耳听也不一定为实,AI语音已能骗得百万巨款
  5. c语言中缀表达式求值_数据结构考研笔记之栈与队列(四)栈与队列应用括号匹配、中缀表达式转前缀后缀问题...
  6. Python进阶(2)
  7. 报名开启!AI+科学计算专场直播:大咖齐聚×独家礼物,限量200份
  8. 恶意软件盯上了加密货币,两家以色列公司受到攻击
  9. 装水体积c语言,C语言基础之--sizeof()运算符的使用以及注意
  10. 3D Vision公开课 | 移动机器人视觉三维感知的现在与将来
  11. Reaction to 构造之法 of Software Engineering From The First Chapter toThe Fifth Chapter
  12. java socket编程—单客户端与服务器通信
  13. windows sesrver2003下搭建DHCP服务器
  14. [数值计算-1]:数学建模、科学计算、数值计算的关系
  15. Unity C# compiler: CS0121: The call is ambiguous between the following methods or properties
  16. harmonyos在哪里使用,HarmonyOS 2.0 手机版使用初体验 ——手机开发者 (Beta版)
  17. VB中LCASE与UCASE
  18. 学术之声 | 专访邵俊教授:区块链用技术保证在链上说话算话
  19. 谁是全球芯片行业的“麒麟才子”?得之可得天下!
  20. 测试工程师的明天在哪里

热门文章

  1. 【实战篇】37 # 如何使用 QCharts 图表库绘制常用数据图表?
  2. java学习笔记—java的学习路线
  3. 记录宝塔面板后台提示“拒绝了我们的连接请求”
  4. openstack-t swift搭建(完美搭建)2021
  5. Omnibus GitLab 使用说明
  6. ping android模拟器,Android模拟器之间的网络通信及Ping主机
  7. 三星 android 模拟器下载地址,GalaxyOfWar电脑版下载 安卓模拟器图文安装教程
  8. Ubuntu下mosquitto 的使用
  9. 使用pandas处理excel,并使用Openpyxl修改单元格格式
  10. 五金自营平台进军MRO百亿市值 行业独角兽势头显现