This is the mail archive of the gdb@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: Help with solaris testing


On Tuesday 05 August 2008 15:29:34, Mark Kettenis wrote:

> On Solaris 10, I get:
>
>
> $ stty
> speed 38400 baud;
> rows = 24; columns = 80; ypixels = 316; xpixels = 484;
> csdata ?
> eucw 1:0:0:0, scrw 1:0:0:0
> intr = ^c; quit = ^\; erase = ^?; kill = ^u;
> eof = ^d; eol = <undef>; eol2 = <undef>; swtch = <undef>;
> start = ^q; stop = ^s; susp = ^z; dsusp = ^y;
> rprnt = ^r; flush = <undef>; werase = ^w; lnext = ^v;
> -parenb -parodd cs8 -cstopb -hupcl cread -clocal -loblk -crtscts -crtsxoff
> -parext -ignbrk brkint -ignpar -parmrk -inpck -istrip -inlcr -igncr icrnl
> -iuclc ixon -ixany -ixoff -imaxbel
> isig icanon -xcase echo echoe echok -echonl -noflsh
> -tostop echoctl -echoprt echoke -defecho -flusho -pendin iexten
> opost -olcuc onlcr -ocrnl -onocr -onlret -ofill -ofdel tab3
>

On a clean login, I get,

pedro@opensolaris:~/orlando/gdb/multi_process/build-solaris/gdb$ stty -a
speed 38400 baud; rows 30; columns 80;
intr = ^C; quit = ^\; erase = ^?; kill = ^U; eof = ^D; eol = <undef>;
eol2 = <undef>; swtch = <undef>; start = ^Q; stop = ^S; susp = ^Z; dsusp = ^Y;
rprnt = ^R; werase = ^W; lnext = ^V; flush = ^O;
-parenb -parodd cs8 -hupcl -cstopb cread -clocal -crtscts
-ignbrk brkint -ignpar -parmrk -inpck -istrip -inlcr -igncr icrnl -ixon -ixoff
-iuclc -ixany -imaxbel
opost -olcuc -ocrnl onlcr -onocr -onlret -ofill -ofdel nl0 cr0 tab3 bs0 vt0 
ff0
isig icanon iexten echo echoe echok -echonl -noflsh -xcase -tostop -echoprt
echoctl echoke

>
> and "stty sane" changes that to:
>
>
> speed 38400 baud;
> rows = 24; columns = 80; ypixels = 316; xpixels = 484;
> csdata ?
> eucw 1:0:0:0, scrw 1:0:0:0
> intr = ^c; quit = ^\; erase = ^?; kill = ^u;
> eof = ^d; eol = <undef>; eol2 = <undef>; swtch = <undef>;
> start = ^q; stop = ^s; susp = ^z; dsusp = ^y;
> rprnt = ^r; flush = <undef>; werase = ^w; lnext = ^v;
> parenb -parodd cs7 -cstopb -hupcl cread -clocal -loblk -crtscts -crtsxoff
> -parext -ignbrk brkint ignpar -parmrk -inpck istrip -inlcr -igncr icrnl
> -iuclc ixon -ixany -ixoff imaxbel
> isig icanon -xcase echo echoe echok -echonl -noflsh
> -tostop echoctl -echoprt echoke -defecho -flusho -pendin iexten
> opost -olcuc onlcr -ocrnl -onocr -onlret -ofill -ofdel
>

And after "stty sane":

pedro@opensolaris:~/orlando/gdb/multi_process/build-solaris/gdb$ /usr/bin/stty
speed 38400 baud; -parity
rows = 30; columns = 80; ypixels = 0; xpixels = 0;
brkint -inpck -istrip icrnl -ixany imaxbel onlcr
echo echoe echok echoctl echoke iexten

pedro@opensolaris:~/orlando/gdb/multi_process/build-solaris/gdb$ /usr/bin/stty -a
speed 38400 baud;
rows = 30; columns = 80; ypixels = 0; xpixels = 0;
csdata ?
eucw 1:0:0:0, scrw 1:0:0:0
intr = ^c; quit = ^\; erase = ^?; kill = ^u;
eof = ^d; eol = <undef>; eol2 = <undef>; swtch = ^z;
start = ^q; stop = ^s; susp = ^z; dsusp = ^y;
rprnt = ^r; flush = ^o; werase = ^w; lnext = ^v;
-parenb -parodd cs8 -cstopb -hupcl 
cread -clocal -loblk -crtscts -crtsxoff -parext
-ignbrk brkint ignpar -parmrk -inpck -istrip -inlcr -igncr icrnl -iuclc
ixon -ixany -ixoff imaxbel
isig icanon -xcase echo echoe echok -echonl -noflsh
-tostop echoctl -echoprt echoke -defecho -flusho -pendin iexten
opost -olcuc onlcr -ocrnl -onocr -onlret -ofill -ofdel

> which seems to be sane enough for me.  But the OpenSolaris defaults that
> Pedro showed don't seem sane to me.

Sorry, I may have mixed up what I showed, because I only learned after
the fact that "stty" != "stty sane".  :-)

Here's a diff of what you see after stty sane, and what I see after stty sane.
The ">" version is yours:

$ /usr/bin/stty -a
> speed 38400 baud;
  speed 38400 baud;
> rows = 24; columns = 80; ypixels = 316; xpixels = 484;
  rows = 30; columns = 80; ypixels = 0; xpixels = 0;
> csdata ?
  csdata ?
> eucw 1:0:0:0, scrw 1:0:0:0
  eucw 1:0:0:0, scrw 1:0:0:0
> intr = ^c; quit = ^\; erase = ^?; kill = ^u;
  intr = ^c; quit = ^\; erase = ^?; kill = ^u;
> eof = ^d; eol = <undef>; eol2 = <undef>; swtch = <undef>;
  eof = ^d; eol = <undef>; eol2 = <undef>; swtch = ^z;
> start = ^q; stop = ^s; susp = ^z; dsusp = ^y;
  start = ^q; stop = ^s; susp = ^z; dsusp = ^y;
> rprnt = ^r; flush = <undef>; werase = ^w; lnext = ^v;
  rprnt = ^r; flush = ^o; werase = ^w; lnext = ^v;
                      ^^^
> parenb -parodd cs7 -cstopb -hupcl cread -clocal -loblk -crtscts -crtsxoff
 -parenb -parodd cs8 -cstopb -hupcl cread -clocal -loblk -crtscts -crtsxoff
                 ^^^
> -parext -ignbrk brkint ignpar -parmrk -inpck istrip -inlcr -igncr icrnl
  -parext -ignbrk brkint ignpar -parmrk -inpck -istrip -inlcr -igncr icrnl
                                                ^^^^
> -iuclc ixon -ixany -ixoff imaxbel
  -iuclc ixon -ixany -ixoff imaxbel
> isig icanon -xcase echo echoe echok -echonl -noflsh
  isig icanon -xcase echo echoe echok -echonl -noflsh
> -tostop echoctl -echoprt echoke -defecho -flusho -pendin iexten
  -tostop echoctl -echoprt echoke -defecho -flusho -pendin iexten
> opost -olcuc onlcr -ocrnl -onocr -onlret -ofill -ofdel
  opost -olcuc onlcr -ocrnl -onocr -onlret -ofill -ofdel

I then went through the all the options I had used in the workaround,
and identified that it is setting onocr that makes the "\r\r\n" go away.

I'm now working around this by replacing /usr/bin/stty by:

 #!/bin/sh

 if [ $# == 1 ] && [ x"$1" == xsane ]
 then
     exec /usr/bin/stty.org $* onocr
 else
     exec /usr/bin/stty.org $*
 fi

The gdb.mi tests all fail because all commands that GDB sends
are echoed back :-(.  If I remove the onocr, the GDB commands are
not output at all.  :-(
MI testing is not important for me, though, so I consider
it a victory that I'm able to test at all...

-- 
Pedro Alves


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