交叉编译 GDB 时出现 Python 丢失或不可用错误

标签 python gdb

我在尝试交叉编译 GDB 时遇到此错误(使用 --with-python 标志):

checking for python: /usr/bin/python
checking for python2.7: no
configure: error: python is missing or unusable

我确保在 /usr/bin 中安装了 python2.7。我什至删除了软件包并重新安装了它。我尝试使用 --with-python=/usr/bin--with-python=/usr/local,但没有成功。虽然安装了 2.7,但我肯定知道。知道该怎么做吗?

最佳答案

我在 Debian 6.0 上编译 GDB 7.4.1 时遇到了同样的问题

解决方案是安装 python header

sudo apt-get install python2.6-dev

然后用正确的标志进行配置

./configure --with-python

关于交叉编译 GDB 时出现 Python 丢失或不可用错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/10792844/

相关文章:

python - 如何排序复合索引来防止插入死锁?

javascript - Scrapy 和 Xpath 从 JavaScript 代码中提取数据

c++ - 为什么 GDB 不能从带有信息符号的地址中找到符号?

python - 使用 gdb 7 对调试 Python 程序的支持需要什么?

debugging - 暂停调试器时 STM32 卡住外围设备

c++ - qapps运行良好但断点有时会产生段错误

python - 简单 Python 函数调用和将其包装在 cProfile.run() 中的区别

python - jedi-vim 没有找到 python2 dist-packages,但是 python3 是的

python - 对一个类进行多重索引?

c++ - GDB:如何找到已加载符号(symbols,symbols,symbols)的内存总大小?