* [PATCH, testsuite] Fix subst.exp failure when GDB is configured with --with-relocated-sources
@ 2013-06-19 20:14 Luis Machado
2013-06-19 20:37 ` Pedro Alves
0 siblings, 1 reply; 3+ messages in thread
From: Luis Machado @ 2013-06-19 20:14 UTC (permalink / raw)
To: 'gdb-patches@sourceware.org'
[-- Attachment #1: Type: text/plain, Size: 384 bytes --]
Hi,
The gdb.base/subst.exp test assumes GDB starts with no default
substitution rules, which is not true if GDB has been configured with
--with-relocated-sources. In that case we start with a default rule,
causing the first test (checking that there are no rules) to fail.
This patch clears any default substitution rules that may exist prior to
doing all the other tests.
OK?
[-- Attachment #2: subst.diff --]
[-- Type: text/x-patch, Size: 829 bytes --]
2013-06-19 Luis Machado <lgustavo@codesourcery.com>
* gdb.base/subst.exp: Delete default rules before further
tests.
diff --git a/gdb/testsuite/gdb.base/subst.exp b/gdb/testsuite/gdb.base/subst.exp
index e339557..50f6620 100644
--- a/gdb/testsuite/gdb.base/subst.exp
+++ b/gdb/testsuite/gdb.base/subst.exp
@@ -23,6 +23,12 @@ gdb_reinitialize_dir $srcdir/$subdir
gdb_test_no_output "set confirm off" \
"deactivate GDB's confirmation interface"
+# Clear any substitution rules that are available by default due
+# to GDB being configured with --with-relocated-sources.
+
+gdb_test_no_output "unset substitute-path" \
+ "remove default substitution rules"
+
gdb_test "show substitute-path" \
"List of all source path substitution rules:" \
"show substitute-path, no rule entered yet"
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: [PATCH, testsuite] Fix subst.exp failure when GDB is configured with --with-relocated-sources
2013-06-19 20:14 [PATCH, testsuite] Fix subst.exp failure when GDB is configured with --with-relocated-sources Luis Machado
@ 2013-06-19 20:37 ` Pedro Alves
2013-06-19 21:04 ` Luis Machado
0 siblings, 1 reply; 3+ messages in thread
From: Pedro Alves @ 2013-06-19 20:37 UTC (permalink / raw)
To: lgustavo; +Cc: 'gdb-patches@sourceware.org'
On 06/19/2013 08:43 PM, Luis Machado wrote:
> Hi,
>
> The gdb.base/subst.exp test assumes GDB starts with no default
> substitution rules, which is not true if GDB has been configured with
> --with-relocated-sources. In that case we start with a default rule,
> causing the first test (checking that there are no rules) to fail.
>
> This patch clears any default substitution rules that may exist prior to
> doing all the other tests.
>
> OK?
>
Looks obviously correct to me.
--
Pedro Alves
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH, testsuite] Fix subst.exp failure when GDB is configured with --with-relocated-sources
2013-06-19 20:37 ` Pedro Alves
@ 2013-06-19 21:04 ` Luis Machado
0 siblings, 0 replies; 3+ messages in thread
From: Luis Machado @ 2013-06-19 21:04 UTC (permalink / raw)
To: Pedro Alves; +Cc: 'gdb-patches@sourceware.org'
On 06/19/2013 05:13 PM, Pedro Alves wrote:
> On 06/19/2013 08:43 PM, Luis Machado wrote:
>> Hi,
>>
>> The gdb.base/subst.exp test assumes GDB starts with no default
>> substitution rules, which is not true if GDB has been configured with
>> --with-relocated-sources. In that case we start with a default rule,
>> causing the first test (checking that there are no rules) to fail.
>>
>> This patch clears any default substitution rules that may exist prior to
>> doing all the other tests.
>>
>> OK?
>>
>
> Looks obviously correct to me.
>
Thanks. Checked in.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2013-06-19 20:37 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-06-19 20:14 [PATCH, testsuite] Fix subst.exp failure when GDB is configured with --with-relocated-sources Luis Machado
2013-06-19 20:37 ` Pedro Alves
2013-06-19 21:04 ` Luis Machado
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox