From: Daniel Jacobowitz <drow@mvista.com>
To: Raoul Gough <RaoulGough@yahoo.co.uk>
Cc: gdb-patches@sources.redhat.com
Subject: Re: [RFA] Add shared object relocation tests
Date: Tue, 03 Jun 2003 13:07:00 -0000 [thread overview]
Message-ID: <20030603130744.GB13577@nevyn.them.org> (raw)
In-Reply-To: <bbhs99$cu$1@main.gmane.org>
On Tue, Jun 03, 2003 at 11:14:44AM +0100, Raoul Gough wrote:
> I've written a test for load-time relocation of shared objects, to verify
> that the symbols in gdb match the real (loaded) locations in memory.
> This was originally designed to test some patches to coffread.c, but
> is probably appropriate wherever shared objects are available. This
> is related to PR 1132 in Gnats. Tested under i686-pc-cygwin and
> i686-pc-linux.
>
> There may be problems on systems where shared objects are not
> supported - this will probably result in compilation or linkage
> failures during the test (and I think the test is then skipped?).
>
> This would add the following files to src/gdb/testsuite/gdb.base:
>
> shreloc.exp
> shreloc.c
> shreloc1.c
> shreloc2.c
>
> 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.
> 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
> }
> }
>
> set additional_flags "additional_flags=-shared"
>
> if {([istarget "*pc-cygwin"] || [istarget "*pc-mingw32"]) } {
> set additional_flags "${additional_flags} -Wl,--image-base,0x04000000"
> }
>
> foreach module [list "shreloc1" "shreloc2"] {
> if {[gdb_compile "${workdir}/${module}.o" "${workdir}/${module}.dll" executable [list debug $additional_flags]] != ""} {
> gdb_suppress_entire_file "${module}.dll link failed, so all tests in this file will automatically fail."
> return -1
> }
> }
>
> if {[gdb_compile [list "${workdir}/shreloc.o" "${workdir}/shreloc1.dll" "${workdir}/shreloc2.dll"] "${workdir}/shreloc" executable
> debug] != ""} {
> gdb_suppress_entire_file "shreloc link failed, so all tests in this file will automatically fail."
> return -1
> }
Please just use return, not gdb_suppress_entire_file. In particular,
using both causes the _next_ test to fail, I think.
Other than those two details, this is OK. Give other people a day or
so to comment and then check it in.
--
Daniel Jacobowitz
MontaVista Software Debian GNU/Linux Developer
next prev parent reply other threads:[~2003-06-03 13:07 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-06-03 10:14 Raoul Gough
2003-06-03 13:07 ` Daniel Jacobowitz [this message]
2003-06-03 14:39 ` Raoul Gough
2003-06-05 9:54 ` Raoul Gough
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20030603130744.GB13577@nevyn.them.org \
--to=drow@mvista.com \
--cc=RaoulGough@yahoo.co.uk \
--cc=gdb-patches@sources.redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox