This is the mail archive of the gdb@sourceware.org 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: Should "dir" override the full path encoded in debug info?


>>>>> "Joel" == Joel Brobecker <brobecker@adacore.com> writes:

 >> It is quite likely that what you really want is not "dir", but
 >> this:
 >> 
 >> http://sourceware.org/ml/gdb/2006-03/msg00189.html
 >> 
 >> Hey, Paul...

 Joel> Indeed, that would solve the proble entirely. I wonder how this
 Joel> should be implemented... Should the command store the rewriting
 Joel> rule, and have find_and_open_source() use it when trying to
 Joel> locate source files?

I forgot where I put it.  What I did is a simple rewriting rule -- a
command with two string arguments, where one is the string to find in
the filenames and the other the replacement string.  A fancier
solution would have multiple substitution pairs, and/or regular
expressions.  For our purposes, one pair with simple strings was
sufficient. 

Once I get out from my current time crunch I'll see about digging up
the change and submitting it as a proposed patch.

    paul


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