一、问题描述

windows系统在Anaconda prompt运行

pip install cx_Oracle

安装cx_Oracle库报错,python版本3.12.7,报错:

  • ERROR: Failed to build installable wheels for some pyproject.toml based projects (cx_Oracle)
  • ERROR: Failed building wheel for cx_Oracle
  • error: Microsoft Visual C++ 14.0 or greater is required. Get it with “Microsoft C++ Build Tools”: https://visualstudio.microsoft.com/visual-cpp-build-tools/
  • error: subprocess-exited-with-error
    在这里插入图片描述

二、原因

上面所有报错,其实关键是下面这条报错造成,是因为电脑缺少Microsoft Visual C++ 14.0 or greater 的编译器,下载并安装Microsoft Visual C++ Build Tools后即可解决问题。

error: Microsoft Visual C++ 14.0 or greater is required. Get it with
“Microsoft C++ Build Tools”:
https://visualstudio.microsoft.com/visual-cpp-build-tools/

三、解决方案

最简单方法下载一个社区版的visualstudio IDE,里面把C++编译器选上安装,VisualStudio免费社区版下载
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述

在这里插入图片描述

在这里插入图片描述

Logo

腾讯云面向开发者汇聚海量精品云计算使用和开发经验,营造开放的云计算技术生态圈。

更多推荐