This is the mail archive of the gdb@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Question about test gdb remotely using gdbserver on uClinux


Hi,

I'm trying to test gdb remotely using gdbserver on uClinux. The cross
toolchain for uClinux generates two target files, for example, foo and
foo.gdb. File foo is in bFLT format, which uClinux can load. File
foo.gdb is in ELF format, which is usuallly used as the symbol file
for debugging.

So we have to pass foo to gdb_load to load it using gdbserver remotely
on the target board. And pass foo.gdb to gdb_file_cmd to load it as
symbol file on host.

Currently, I add ".gdb" to the argument of each gdb_file_cmd or
similar procedures in gdb testsuite. This is ugly. My plan is to add a
field to target board, like "symbol_file_name_extension" or a more
powerful transform helper procedure "infer_symbol_file_name". At each
place calling gdb_file_cmd or similar procedures, concatenate
"symbol_file_name_extension" to the its argument or use the result of
"infer_symbol_file_name" as its argument if they are defined in the
target board configuration.

I don't know if there are any such like mechanism. There are
gdbsever_host_exec and gdbserver_server_exec in gdbserver-support.exp.
I'm not clear if and how they can be used for my specific purpose.

Thanks,
Jie


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]