gcc - Not getting debugging symbols to be generated -


i using make , debugging symbols not getting generated. here makefile:

program: ui.o data.o string.o         c99 -ggdb -o program2 ui.o data.o string.o  clean :         rm -f program2  ui.o : ui.c data.h         c99 -ggdb -c ui.c  data.o : data.c data.h         c99 -ggdb -c data.c  string.o : string.c string.h         c99 -ggdb -c string.c 

how can generate debugging symbols? when run gdb using gdb program2 gives warning "no debugging symbols found".

  1. your makefile builds program2, pretends build program (i.e. target on first line wrong).
  2. your clean target should clean *.o, otherwise make clean; make relink program, not recompile objects in it.

one of above factors explanation missing debug symbols you've observed.


Comments

Popular posts from this blog

How to start daemon on android by adb -

Angularjs unit testing - ng-disabled not working when adding text to textarea -

testing - Detect whether test has failed within fixture -