C++ embedding Python
C++ embedding Python
我想用C++运行Python-Scripts。
在我的书中,有以下内容:
#include <Python.h>
... at main function some calls
但是在编译编译器找不到Python头文件时。
我该如何解决这个问题?
在Linux Mint上,sudo apt-get install python-dev
应该可以完成这项工作。 这将获取并安装 python 开发文件。
这应该将包含文件放在/usr/include/python2.7/
,因此您需要将-l /usr/include/python2.7/
添加到编译器标志中。
'
相关文章:
- 如何运行位于boost/libs/python/example/tutorial目录中的hello.cpp和Jamfil
- Pybind11:将元组列表从Python传递到C++
- 如何在c++中使用引用实现类似python的行为
- 是否可以通过C++扩展强制多个python进程共享同一内存
- 递归列出所有目录中的C++与Python与Ruby的性能
- IPC使用多个管道和分支进程来运行Python程序
- 从python中调用C++函数并获取返回值
- Python 3.7 和 excess_args 的 SWIG 问题
- Python中的for循环与C++有何不同
- 使用Pybind11向Python公开Eigen::张量
- Python str to C++ to Python str
- 如何使用Python从C++中读取谷物序列化数据
- 如何在C++中使用pybind11加载一个pickle python列表
- 如何在c++中使用system()来运行包含空格的python脚本
- python集合的C++等价物是什么.计数器
- 如果C++对象的类在另一个boost模块中声明,如何使用boost将指向该对象的指针返回到python
- Embedding Python with C++
- C++ embedding Python
- Python 3未通过Boost.Python Embedding将C++类识别为模块
- PhysFS and Python embedding