gdb加载python脚本的方法
来源:互联网 发布:工业大数据 智能制造 编辑:程序博客网 时间:2024/05/22 15:38
脚本名称为hello.py,内容如下:
import gdb class HelloPrefixCommand( gdb.Command ): "just to say hello" def __init__(self): super( HelloPrefixCommand, self).__init__("hello", gdb.COMMAND_SUPPORT, gdb.COMPLETE_NONE, True )HelloPrefixCommand()
加载方法1:
sudo gdb httpd -x hello.py
查看一下:
(gdb) help hellojust to say helloList of hello subcommands:Type "help hello" followed by hello subcommand name for full documentation.Type "apropos word" to search for commands related to "word".Command name abbreviations are allowed if unambiguous.
加载方法2:
(gdb) source hello.py
查看一下:
(gdb) help hellojust to say helloList of hello subcommands:Type "help hello" followed by hello subcommand name for full documentation.Type "apropos word" to search for commands related to "word".Command name abbreviations are allowed if unambiguous.
阅读全文
0 0
- gdb加载python脚本的方法
- Python动态加载脚本的方法
- 使用gdb调试python脚本
- Python脚本批量合并GDB
- 判断脚本是否加载完成的方法
- 动态加载js脚本的方法
- js实现动态加载脚本的方法
- Python加载图片的方法
- Javascript(加快脚本加载速度的方法:压缩脚本文件。)
- gdb的脚本使用 -- gdbinit
- gdb的脚本使用 -- gdbinit
- 编译python脚本成exe的方法
- 运行python脚本的几种方法
- python脚本的调试方法讲解
- python调用shell脚本的方法
- 运行Python脚本的一种方法
- Python 调用 Shell脚本的方法
- Python 脚本获取上一个工作日的方法
- TensorFlow学习笔记2:构建CNN模型
- Java初学者必看2
- java二进制正数和负数取反
- 模板的分离编译
- C/C++中如何使用typedef给函数指针取别名使其更具可读性
- gdb加载python脚本的方法
- 学习日记6
- 写一个函数满足:给定一个int list a,满足a[i+1]>=a[i],给定int key,找出list a中第一个大于等于key的元素的index,无满足要求的元素则返回-1.
- 数据库优化策略小结
- POJ
- Python 常用技巧(待续)
- POJ 3650 The Seven Percent Solution
- 解决点击edittext时有时无法弹出软键盘的问题
- 算法——冒泡排序