PDA

View Full Version : gdb debugging symbols


Mason
02-01-2006, 14:18
ho un problema a generare i simboli di debug, che dovrebbe essere una cretinata

-<mason@ariel>--<lun 2- 2:07>-$ gdb -<vim>-
GNU gdb 6.3
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for details.
This GDB was configured as "i486-slackware-linux".
(gdb) file /opt/bin/vim
Reading symbols from /opt/bin/vim...(no debugging symbols found)...done.
Using host libthread_db library "/lib/tls/libthread_db.so.1".

questo quando cerco di eseguirlo

per quanto riguarda invece da root

-<root@ariel>--<lun 2- 2:16>-$ export|grep CFLA -<vim>-
CFLAGS='-Os -march=pentium3 -fomit-frame-pointer -pipe -g'

naturalmente seguito da un make && make install

visto che non funge, dove sbaglio? dovrebbe essere una cretinata ma non funge.

ilsensine
02-01-2006, 14:44
Innanzitutto, ti consiglio di tenere il frame pointer quando compili per debug. Quindi, usa un livello di debug "alto" (ad es. -g3). Infine, verifica che i simboli di debug non vengano "strippati" (-s) in fase di link.

Mason
02-01-2006, 15:30
risolto thx, lo strippava in fase di installazione

cp vim /opt/bin
strip /opt/bin/vim
ho ricopiato il binario dopo l'installazione ed ora funge, thx x il g3 che non conoscevo