2
”ERROR: Failed building wheel for Polygon3“ 安装Polygon3时提示错误的解决方法
source link: https://www.nixonli.com/105.html
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
在安装CnOCR是需要使用到Polygon3这个包,安装时提示报错,需要使用到Microsoft Visual C++ 14.0。
需要下载的工具:Microsoft C++ 编译工具(Microsoft C++ Build Tools)
下载地址:https://visualstudio.microsoft.com/visual-cpp-build-tools/
错误提示:
Building wheels for collected packages: Polygon3 Building wheel for Polygon3 (pyproject.toml) ... error error: subprocess-exited-with-error × Building wheel for Polygon3 (pyproject.toml) did not run successfully. │ exit code: 1 ╰─> [14 lines of output] NumPy extension not found - disabling support for it! running bdist_wheel running build running build_py creating build creating build\lib.win-amd64-cpython-310 creating build\lib.win-amd64-cpython-310\Polygon copying Polygon\IO.py -> build\lib.win-amd64-cpython-310\Polygon copying Polygon\Shapes.py -> build\lib.win-amd64-cpython-310\Polygon copying Polygon\Utils.py -> build\lib.win-amd64-cpython-310\Polygon copying Polygon\__init__.py -> build\lib.win-amd64-cpython-310\Polygon running build_ext building 'Polygon.cPolygon' extension 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/ [end of output] note: This error originates from a subprocess, and is likely not a problem with pip. ERROR: Failed building wheel for Polygon3 Failed to build Polygon3 ERROR: Could not build wheels for Polygon3, which is required to install pyproject.toml-based projects PS D:\SynologyDrive> pip install Polygon3 Collecting Polygon3 Using cached Polygon3-3.0.9.1.tar.gz (39 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Installing backend dependencies ... done Preparing metadata (pyproject.toml) ... done Building wheels for collected packages: Polygon3 Building wheel for Polygon3 (pyproject.toml) ... error error: subprocess-exited-with-error × Building wheel for Polygon3 (pyproject.toml) did not run successfully. │ exit code: 1 ╰─> [14 lines of output] NumPy extension not found - disabling support for it! running bdist_wheel running build running build_py creating build creating build\lib.win-amd64-cpython-310 creating build\lib.win-amd64-cpython-310\Polygon copying Polygon\IO.py -> build\lib.win-amd64-cpython-310\Polygon copying Polygon\Shapes.py -> build\lib.win-amd64-cpython-310\Polygon copying Polygon\Utils.py -> build\lib.win-amd64-cpython-310\Polygon copying Polygon\__init__.py -> build\lib.win-amd64-cpython-310\Polygon running build_ext building 'Polygon.cPolygon' extension 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/ [end of output] note: This error originates from a subprocess, and is likely not a problem with pip. ERROR: Failed building wheel for Polygon3 Failed to build Polygon3 ERROR: Could not build wheels for Polygon3, which is required to install pyproject.toml-based projects
下载并安装Microsoft C++ 生成工具进行MSVC v140-VS 2015 C++生成工具的安装
打开安装工具搜索”Visual C++ 14.0″选择”MSVC v140 – VS 2015 C++生成工具(v14.00)“:
工具安装好即可。
如果提示LINK : fatal error LNK1158: 无法运行“rc.exe”
请查看此文章:https://www.nixonli.com/?p=106
Recommend
About Joyk
Aggregate valuable and interesting links.
Joyk means Joy of geeK