顺藤摸瓜的解决GDB的DEBUG中出现的小问题

1,在运行GDB的R指令时,报错。。。。

(gdb) r

Starting program: /root/tst

Breakpoint 1, main () at tst.c:17

17              long result=0;

Missing separate debuginfos, use: debuginfo-install glibc-2.12-1.80.el6_3.6.x86_64

2,按提示,运行debuginfo-install glibc-2.12-1.80.el6_3.6.x86_64时报错:

debuginfo-install glibc-2.12-1.80.el6_3.6.x86_64
-bash: debuginfo-install: command not found

3,网上搜索,找到有用的。

http://*.com/questions/10352546/how-to-install-glibc-with-debugging-info-on-centos-5-5

http://hi.baidu.com/patrick_zhow/item/226b650d474fb43ef3eafcc8

 

For this to work, you need to have the debuginfo repository defined.  For CentOS 5, put the following in /etc/yum.repos.d/CentOS-Base-debuginfo.repo:

[base-debuginfo]
name=CentOS-$releasever -DebugInfo
baseurl=http://debuginfo.centos.org/$releasever/$basearch/
gpgcheck=0
enabled=0
protect=1
priority=1
~~~~~~~
debuginfo-install is part of the yum-utils package. 
If you don't know what package contains a command,
you can try something like yum install /usr/bin/debuginfo-install
and yum will find it for you (assuming that the package you want is in /usr/bin)
~~~~~~~~
4,问题解决

顺藤摸瓜的解决GDB的DEBUG中出现的小问题

顺藤摸瓜的解决GDB的DEBUG中出现的小问题

上一篇:点击复制内容到剪切板并打开微信


下一篇:ecshop侧面添加自定义菜单方法以及之后操作方法