From: Simon Marchi <simon.marchi@ericsson.com>
To: Pedro Alves <palves@redhat.com>, <gdb-patches@sourceware.org>
Subject: Re: [PATCH] Remove symlinks created in argv0-symlink.exp and general cleanup
Date: Mon, 03 Aug 2015 15:16:00 -0000 [thread overview]
Message-ID: <55BF85BC.8040102@ericsson.com> (raw)
In-Reply-To: <55BF7962.3060106@redhat.com>
On 15-08-03 10:23 AM, Pedro Alves wrote:
> On 07/30/2015 09:13 PM, Simon Marchi wrote:
>> When running argv0-symlink.exp, symlinks are left in the test output
>> directory. One of them is a recursive symlink. This causes the same tests
>> to be found multiple times and disturbs subsequent test runs.
>>
>> To witness it simply, just run
>>
>> $ make check RUNTESTFLAGS="argv0-symlink.exp"
>>
>> twice in a row. The second run will find and run argv0-symlink.exp
>> multiple times because of the recursive symlink left by the first run. Note
>> that this only happens when building in tree. The simple fix is to
>> remove the links when we are done.
>>
>> At the same time, I did a general cleanup of the test:
>>
>> - Add and use a create_link proc.
>
>> - Bail out early if target does not support argv[0].
>
> What's the rationale for that? It seems that'd skip the
> tests that ensure that "info inferiors" shows the $filelink; those
> aren't currently guarded by $has_argv. AFAICS, that was done
> on purpose. See:
>
> git show 673dc4a0
> git show 673dc4a0:gdb/testsuite/gdb.base/argv0-symlink.exp
Right.
>> - Of course, remove created symlinks before returning.
>
> I think you should leave them, actually. That's a general direction
> we've been following -- leaving build/test artifacts in place in case
> the test fails and we need to debug what happened.
> So instead what we do is remove any leftover from a previous run
> that could interfere, when we start a new run. (I think the patch
> is already doing that too.)
It makes sense.
The problem is that it also affects when running other tests.
For example, doing a
$ make check RUNTESTFLAGS="argv0-symlink.exp"
and then
$ make check RUNTESTFLAGS="whatis.exp"
gives
http://paste.ubuntu.com/11993577/
At least, it's possible to avoid it by doing
$ make check RUNTESTFLAGS="gdb.base/whatis.exp"
instead. However, it also affect those as well:
$ make check
$ make check RUNTESTFLAGS="--directory=gdb.base"
runtest will find all tests recursively, resulting in this:
http://paste.ubuntu.com/11993659/
Building out-of-tree would avoid this altogether, of course. The
reason I build in-tree is that I use a script [1] to regression-test
my patches. The script is a bit dumb and requires to build in the
git repo. I think I'll improve it a bit to make it possible to
build OOT.
Simon
[1] https://github.com/simark/gdb-check
next prev parent reply other threads:[~2015-08-03 15:16 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-07-30 20:13 Simon Marchi
2015-08-03 14:23 ` Pedro Alves
2015-08-03 15:16 ` Simon Marchi [this message]
2015-08-03 16:34 ` Pedro Alves
2015-08-03 16:38 ` Pedro Alves
2015-08-03 18:10 ` Simon Marchi
2015-08-03 18:42 ` Pedro Alves
2015-08-04 16:11 ` Sergio Durigan Junior
2015-08-04 17:21 ` Joel Brobecker
2015-08-11 17:36 ` Doug Evans
2015-08-11 19:58 ` Joel Brobecker
2015-08-11 20:43 ` Doug Evans
2015-08-11 23:02 ` Joel Brobecker
2015-08-12 9:30 ` Pedro Alves
2015-08-12 16:40 ` Sergio Durigan Junior
2015-08-12 17:22 ` Joel Brobecker
2015-08-12 17:38 ` Doug Evans
2015-08-12 18:43 ` Joel Brobecker
2015-08-12 18:50 ` Doug Evans
2015-08-12 19:41 ` Joel Brobecker
2015-08-12 20:23 ` Doug Evans
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=55BF85BC.8040102@ericsson.com \
--to=simon.marchi@ericsson.com \
--cc=gdb-patches@sourceware.org \
--cc=palves@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