This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
Re: [RFA] Add shared object relocation tests
- From: Raoul Gough <RaoulGough at yahoo dot co dot uk>
- To: gdb-patches at sources dot redhat dot com
- Date: Tue, 03 Jun 2003 15:39:05 +0100
- Subject: Re: [RFA] Add shared object relocation tests
- Cancel-lock: sha1:mmMoanZRS3+KbymmED/dRJ4DRw4=
- References: <bbhs99$cu$1@main.gmane.org> <20030603130744.GB13577@nevyn.them.org>
Daniel Jacobowitz <drow@mvista.com> writes:
> On Tue, Jun 03, 2003 at 11:14:44AM +0100, Raoul Gough wrote:
[snip]
>> Should I go ahead and add the new files?
>
> First of all, even new files get a changelog entry. It will go in
> gdb/testeuite/ChangeLog.
Thanks for pointing this out - I'd forgotten this entirely. The
src/gdb/testsuite/ChangeLog entry would be:
2003-06-03 Raoul Gough <RaoulGough@yahoo.co.uk>
* gdb.base/shreloc.exp: New file, check symbols obtained from shared
objects that required relocation at load time (gdb PR/1132).
* gdb.base/shreloc.c, gdb.base/shreloc1.c, gdb.base/shreloc2.c:
as above, part of the shared object relocation test.
>
>> foreach module [list "shreloc" "shreloc1" "shreloc2"] {
>> if {[gdb_compile "${srcdir}/${subdir}/${module}.c" "${workdir}/${module}.o" object {debug}] != ""} {
>> gdb_suppress_entire_file "${module}.c compile failed, so all tests in this file will automatically fail."
>> return -1
>> }
>> }
[snip similar cases]
>
> Please just use return, not gdb_suppress_entire_file. In particular,
> using both causes the _next_ test to fail, I think.
Hmmm.... gdb_suppress_entire_file seems to be the usual response to
testcase compilation failures, so it would probably make more sense to
remove the return statement instead. I don't really know what the pros
and cons are in this case - is there some reason to prefer the return
option (what about logging the error in that case?)
>
> Other than those two details, this is OK. Give other people a day or
> so to comment and then check it in.
Thanks for the feedback, and I'll hold off for a couple of days on the
update.
--
Raoul Gough
"Let there be one measure for wine throughout our kingdom, and one
measure for ale, and one measure for corn" - Magna Carta