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]

Re: gdb.mi/*.exp and absolute line numbers


Andrew Cagney <cagney@gnu.org> wrote:
> (What happens with a soft-link or file copy (where the file name isn't 
> in $srcdir) as is done with the asm tests).

This call would stop working:

  [gdb_get_line_number "foo" arch.inc]

However this call would work fine:

  [gdb_get_line_number "foo" ${asm-arch}.inc]

Fortunately there are no such calls in the corpus, so it won't hurt when
I change the semantics from "gdb looks for the file on the host machine"
to "tcl looks for the file on the build machine".

The test script always has to know the names of the files on the build
machine, in order to get them to the host machine in the first place.

Something like gdb.stabs/weird.exp would be more painful, because it
actually runs 'sed' on the *host* machine to preprocess files before
feeding them to gdb_compile.  For something like that, if it called
gdb_get_line_number, I would have to rip out the call and replace
it with an explicit call to "gdb_test search".

Michael C


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