OVH Cloud OVH Cloud

Why can't I use gdb?

1 réponse
Avatar
Linda
After I type "make" on the screen, I got the following result:

/usr/local/sunone/SUNWspro/bin/CC -xs -pto -PIC -xtarget=3Dultra
-xarch=3Dv9 -DIL_STD -g -xs -DNDEBUG
-I/usr/local/ilog/solver60/include
-I/usr/local/ilog/solver60/../concert20/include
-I/usr/local/ilog/solver60/examples/include
/uac/rshr/xhji/Ilog/money.cpp -c
/usr/local/sunone/SUNWspro/bin/CC -xs -pto -PIC -xtarget=3Dultra
-xarch=3Dv9 -DIL_STD -g -xs -DNDEBUG
-I/usr/local/ilog/solver60/include
-I/usr/local/ilog/solver60/../concert20/include
-I/usr/local/ilog/solver60/examples/include money.o -o money -g
-L/usr/local/ilog/solver60/lib/ultrasparc64_8_6.2/static_pic_mt
-L/usr/local/ilog/solver60/../concert20/lib/ultrasparc64_8_6.2/static_pic_m=
=ADt

-lsolverfloat -lsolver -lconcert -lsocket -lnsl -lm -lsunmath


We can see that "-g" is there. But when I type "gdb money"(money is my
executable file name:)), I get:


GNU gdb 5.0
Copyright 2000 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
"sparc-sun-solaris2.6"..."/data/a1/rshr/xhji/Ilog/money": not in
executable format: File format not recognized


So I cannot debug normally! Then what's wrong with it? How can I debug
with gdb or dbx normally?=20


Thanks!

1 réponse

Avatar
Fabien LE LEZ
Please post messages written in English on comp.lang.c++.