This is the mail archive of the gdb-patches@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: [PATCH] Fix mingw32 failures due to incorrect directory separator in pattern


On 10/14/2014 09:31 AM, Yao Qi wrote:
Luis Machado <lgustavo@codesourcery.com> writes:

Some testcases, mostly gdb.reverse ones, assume the presence of a '/'
directory separator before the source file name. This is incorrect for
mingw32 hosts, generating false failures for those tests.

These fails are remote host related, not only specific to mingw32.  In
remote host testing, source files can be copied to the place without
directory separator.  These fails this patch fixes can be reproduced on
remote linux host with a modified board file
local-remote-host-native.exp too,

$ make check RUNTESTFLAGS="--host_board=local-remote-host-native --target_board=local-remote-host-native  py-breakpoint.exp"

FAIL: gdb.python/py-breakpoint.exp: test_bkpt_deletion: continue to breakpoint: Break at multiply.
FAIL: gdb.python/py-breakpoint.exp: test_bkpt_deletion: continue to breakpoint: Break at end.
FAIL: gdb.python/py-breakpoint.exp: test_bkpt_eval_funcs: continue to breakpoint: Break at multiply, i==3
FAIL: gdb.python/py-breakpoint.exp: test_bkpt_eval_funcs: continue to breakpoint: Break at multiply, count==1
FAIL: gdb.python/py-breakpoint.exp: test_bkpt_temporary: continue to breakpoint: Break at multiply.

We hack ${board}_download in local-remote-host-native.exp

proc ${board}_download { board src dest } {
     global env

     # Copy file to $HOME and return its base name.
     set destfile [file tail $src]
     file copy -force $src /home/$env(USER)/$destfile

     return $destfile
}

I attempted to catch most of the occurrences of the pattern
".*/$srcfile" and replaced them with ".*$srcfile". The latter is used
elsewhere in the testsuite. The resulting patch is attached.

I also see other occurrences of the same assumption throughout the
testsuite, but usually they are arguments for function calls and i
seem to recall either the test harness or GDB deals with those paths
properly.

Is the attached OK?

It is OK.


Thanks for the feedback Yao. I've pushed this one in now.

Luis


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