python - 为什么在安装 slycot 时出现此 CMAKE_C_COMPILER 错误?
问题描述
早上好/晚上好,
我正在尝试通过 pip install 安装 slycot。不幸的是,我收到以下错误消息。
我已经安装了 CMake。关于如何解决这个问题的任何想法?
谢谢
slycot (PEP 517) 的构建轮...错误错误:命令错误退出状态为 1:命令:'c:\users\francescos\python38\python.exe''c:\users\francescos\python38\lib\站点包\pip_vendor\pep517_in_process.py' build_wheel 'C:\Users\FRANCE~1\AppData\Local\Temp\tmp96ecekd1' cwd: C:\Users\FRANCESCOS\AppData\Local\Temp\pip-install-o1zu4kc_\ slycot_1832234bc3214bdf8ec3b243db79b538 完整输出(56 行):不搜索命令行中给出的未使用变量。-- C 编译器标识未知 CMakeLists.txt:3 (ENABLE_LANGUAGE) 处的 CMake 错误:CMAKE_C_COMPILER:
cl
is not a full path and was not found in the PATH.
To use the NMake generator with Visual C++, cmake must be run from a shell
that can use the compiler cl from the command line. This environment is
unable to invoke the cl compiler. To fix this problem, run cmake from the
Visual Studio Command Prompt (vcvarsall.bat).
Tell CMake where to find the compiler by setting either the environment
variable "CC" or the CMake cache entry CMAKE_C_COMPILER to the full path to
the compiler, or to the compiler name if it is in the PATH.
-- 配置不完整,出现错误!另请参见“C: /Users/FRANCESCOS/AppData/Local/Temp/pip-install-o1zu4kc_/slycot_1832234bc3214bdf8ec3b243db79b538/cmake_test_compile/build/CMakeFiles/CMakeOutput.log”。另请参阅“C:/Users/FRANCESCOS/AppData/Local/Temp/pip-install-o1zu4kc/slycot_1832234bc3214bdf8ec3b243db79b538/_cmake_test_compile/build/CMakeFiles/CMakeError.log"。FC ('-DCMAKE_Fortran_COMPILER=', 'c:/users/francescos/python38/Library/bin/flang.exe') F2PY ('-DF2PY_EXECUTABLE=', ' c:/users/francescos/python38/Scripts/f2py.exe') NUMPY_INCLUDE ('-DNumPy_INCLUDE_DIR=', 'c:/users/francescos/python38/Include') ['-DSLYCOT_VERSION:STRING=0.4.0', ' -DGIT_REVISION:STRING=ac0944b363a6cfcc0c3d5128cdd484d74173aa3b', '-DISRELEASE:STRING=True', '-DFULL_VERSION=0.4.0.gitac0944b', '-GNMake Makefiles', '-DCMAKE_Fortran_COMPILER=c:/users/francescos/python38 /flang.exe', '-DF2PY_EXECUTABLE=c:/users/francescos/python38/Scripts/f2py.exe', '-DNumPy_INCLUDE_DIR=c:/users/francescos/python38/Include', '-DCMAKE_Fortran_SIMULATE_VERSION=5.0.0', '-DCMAKE_Fortran_COMPILER_ID=法兰', '-DCMAKE_VERBOSE_MAKEFILE:BOOL=ON']
scikit-build 无法为您的系统获取工作生成器。中止构建。
为 Python 3.8 构建 windows 轮子需要 Microsoft Visual Studio 2017。使用“Visual Studio 2017”获取它:
https://visualstudio.microsoft.com/vs/
错误:为 slycot 构建轮子失败 未能构建 slycot 错误:无法为使用 PEP 517 且无法直接安装的 slycot 构建轮子
解决方案
推荐阅读
- python - 如何设计模块的良好结构以使导入不会可怕?
- node.js - 无法从节点 API 获取数据
- three.js - threejs如何使点有方向
- java - 休眠 | 为什么事务“半提交”
- apache-camel - apache camel使用简单读取和打印文件内容不起作用
- angular - 将角度项目文件上传和拖动到github的问题
- php - 在 Laravel Eloquent 对象上获取关系方法名称的最有效方法是什么?
- nginx - 将 nginx 日志发送到 syslog 和 stdout/stderr
- redis - Redis - 从三个排序集中获取聚合分数
- python - Python ImportError:没有名为 pygments 的模块