Here are two separate questions.
Firstly, is it possible to modify a makefile so that it produces a.out that is readable by GDB? Secondly, in a makefile, how to disable all the warning messages on the screen output?
Here is the content of the makefile:
ALL: timefield eqloc3d getdat
timefield: timefield.c common.c common.h getpar.c time_3d.c modresample.c eq.c eq.h
cc timefield.c common.c getpar.c time_3d.c modresample.c eq.c ./libgeo.a -lsunmath -lm -g -o timefield
eqloc3d: deri.c eqloc3d.c getpar.c main.c modresample.c common.h common.c modifyxy.c modifyxyz.c eqloc3d.h eq.c eq.h model.h initeqloc.h initeqloc.c
cc deri.c eqloc3d.c getpar.c main.c modresample.c common.c modifyxy.c modifyxyz.c eq.c initeqloc.c ./libgeo.a -lsunmath -lm -xlic_lib=sunperf -g -o eqloc3d
getdat: eq.c eq.h getdat.c
cc -g eq.c getdat.c -o getdat libgeo.a -lm
If I run the makefile, it creates three binary executables: timefield, eqloc3d, getdat. Once the program is not producing correct outputs, I do not have an a.out so that I can use GDB to trace exceptions.