您好, 欢迎来到 !    登录 | 注册 | | 设为首页 | 收藏本站

Python.h:没有这样的文件或目录

Python.h:没有这样的文件或目录

在您的CMakeLists.txt中,尝试添加以下内容

find_package(PythonLibs required)
include_directories(${PYTHON_INCLUDE_DIRS})
target_link_libraries(<your exe or lib> ${PYTHON_LIBRARIES})

有关命令的详细信息,请运行:

cmake --help-module FindPythonLibs
cmake --help-command find_package
cmake --help-command include_directories
cmake --help-command target_link_libraries
python 2022/1/1 18:36:08 有221人围观

撰写回答


你尚未登录,登录后可以

和开发者交流问题的细节

关注并接收问题和回答的更新提醒

参与内容的编辑和改进,让解决方法与时俱进

请先登录

推荐问题


联系我
置顶