当前位置:网站首页>fatal error C1083 Unable to open include file 'io.h' No such file

fatal error C1083 Unable to open include file 'io.h' No such file

2022-08-10 14:53:00 the way of code

原文链接

报错

使用pip安装模块,出现错误:

c:\users\anaconda3\include\pyconfig.h(68): fatal error C1083: 无法打开包括文件: “io.h”: No such file or directory

error: command 'C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\BIN\x86_amd64\cl.exe' failed with exit status 2 Command "C:\Users\Anaconda3\python.exe -u -c "import setuptools, tokenize;file='C:\Users\AppData\Local\Temp\pip-build-4u1qzu cg\lmdb\setup.py';exec(compile(getattr(tokenize, 'open', open)(file).read().replace('\r\n', '\n'), file, 'exec'))" install --record C: \Users\AppData\Local\Temp\pip-bcivjbyw-record\install-record.txt --single-version-externally-managed --compile" failed with error code 1 in C:\Users\AppData\Local\Temp\pip-build-4u1qzucg\lmdb\

原因:无法找到io.h文件.

解决办法

首先安装Windows 10 SDK

SDK下载地址:https://developer.microsoft.com/zh-cn/windows/downloads/windows-10-sdk

默认安装即可.

然后配置路径:右键我的电脑——属性——高级系统设置——环境变量——系统变量(s),在PATH中添加:

C:\Program Files (x86)\Windows Kits\10\Include\<version>\ucrt

即可解决该问题.

   

学习更多编程知识,请关注我的公众号:

代码的路

原网站

版权声明
本文为[the way of code]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/222/202208101431161976.html