[RFH] Cygwin (EXEEXT) fix.

Pedro Alves pedro_alves@portugalmail.pt
Sun Dec 10 14:38:00 GMT 2006


Hi all,

(I know this is a bit offtopic here, since it has mostly to do with my 
lack of tcl knowledge.)

There is a fail on gdb.base/annota3.exp on Cygwin related to a missing 
EXEEXT that
I need help in fixing.

Where is reads '.*annota3' in:

gdb_expect_list "run until main breakpoint" "$gdb_prompt$" {
    "\r\n\032\032post-prompt\r\n"
    "Starting program: .*annota3 \r\n"
    "\r\n\032\032starting\r\n"
    "\r\n\032\032breakpoint 1\r\n"
(...)

My first approach was:
-    "Starting program: .*annota3 \r\n"
+    "Starting program: .*annota3${EXEEXT} \r\n"

But that doesn't work: The variable doesn't get expanded.

Doing:
-    "Starting program: .*annota3 \r\n"
+    "Starting program: .*annota3" [$EXEEXT] " \r\n"

... also doesn't work, much to my surprise, since I copied the syntax 
from gdb.arch/altivec-regs.exp :

(...)
gdb_expect_list "info vector" ".*$gdb_prompt $" {
[$pattern0]
[$pattern1]
(...)

I see that uppercase/lowercase makes a difference, since, if I do a:

+ set exeext ".exe"

-    "Starting program: .*annota3 \r\n"
+    "Starting program: .*annota3" [$exeext] " \r\n"

The regex always passes, no matter what I put in $exeext, even if I put 
something like "asdfad".

How does one go about fixing this?

Cheers,
Pedro Alves

-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: annota3.diff
URL: <http://sourceware.org/pipermail/gdb-patches/attachments/20061210/3f03f796/attachment.ksh>


More information about the Gdb-patches mailing list