我试图在gdb中使用调试符号运行Debian 7.7.0附带的exim4邮件服务器。我使用apt-get install exim4-dbg安装了调试符号,它似乎位于/ usr / lib / debug中。当我尝试连接到exim进程时,我得到以下结果:(没有找到调试符号)
Attaching to process 25318
Reading symbols from /usr/sbin/exim4...(no debugging symbols found)...done.
Reading symbols from /lib/i386-linux-gnu/i686/cmov/libresolv.so.2...(no debugging symbols found)...done.
Reading symbols from /lib/i386-linux-gnu/i686/cmov/libnsl.so.1...(no debugging symbols found)...done.
Reading symbols from /lib/i386-linux-gnu/i686/cmov/libcrypt.so.1...(no debugging symbols found)...done.
Reading symbols from /lib/i386-linux-gnu/i686/cmov/libm.so.6...(no debugging symbols found)...done.
Reading symbols from /lib/i386-linux-gnu/i686/cmov/libdl.so.2...(no debugging symbols found)...done.
Reading symbols from /usr/lib/i386-linux-gnu/libdb-5.1.so...(no debugging symbols found)...done.
Reading symbols from /usr/lib/i386-linux-gnu/libgnutls.so.26...(no debugging symbols found)...done.
Reading symbols from /lib/i386-linux-gnu/libpcre.so.3...(no debugging symbols found)...done.
Reading symbols from /lib/i386-linux-gnu/i686/cmov/libc.so.6...(no debugging symbols found)...done.
Reading symbols from /lib/ld-linux.so.2...(no debugging symbols found)...done.
Reading symbols from /lib/i386-linux-gnu/i686/cmov/libpthread.so.0...(no debugging symbols found)...done.
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/i386-linux-gnu/i686/cmov/libthread_db.so.1".
Reading symbols from /usr/lib/i386-linux-gnu/libtasn1.so.3...(no debugging symbols found)...done.
Reading symbols from /lib/i386-linux-gnu/libgcrypt.so.11...(no debugging symbols found)...done.
Reading symbols from /lib/i386-linux-gnu/libz.so.1...(no debugging symbols found)...done.
Reading symbols from /usr/lib/i386-linux-gnu/libp11-kit.so.0...(no debugging symbols found)...done.
Reading symbols from /lib/i386-linux-gnu/libgpg-error.so.0...(no debugging symbols found)...done.
Reading symbols from /lib/i386-linux-gnu/i686/cmov/libnss_compat.so.2...(no debugging symbols found)...done.
Reading symbols from /lib/i386-linux-gnu/i686/cmov/libnss_nis.so.2...(no debugging symbols found)...done.
Reading symbols from /lib/i386-linux-gnu/i686/cmov/libnss_files.so.2...(no debugging symbols found)...done.
Reading symbols from /lib/libnss_mdns4_minimal.so.2...(no debugging symbols found)...done.
Reading symbols from /lib/i386-linux-gnu/i686/cmov/libnss_dns.so.2...(no debugging symbols found)...done.
Reading symbols from /lib/libnss_mdns4.so.2...(no debugging symbols found)...done.
0xb765c424 in __kernel_vsyscall ()
(gdb) show debug-file-directory
The directory where separate debug symbols are searched for is "/usr/lib/debug".
(gdb) list
No symbol table is loaded. Use the "file" command.
(gdb)
非常感谢任何帮助。谢谢!
答案 0 :(得分:1)
你正在做正确的事。您只需要comp a b
| length a > length b = GT
| length a < length b = LT
或apt-get install exim4-daemon-light-dbg
。然后gdb应该按照你当前运行它的方式找到这些符号。