From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 1362 invoked by alias); 13 Jun 2009 20:29:17 -0000 Received: (qmail 1330 invoked by uid 22791); 13 Jun 2009 20:29:16 -0000 X-SWARE-Spam-Status: No, hits=-2.2 required=5.0 tests=AWL,BAYES_00 X-Spam-Check-By: sourceware.org Received: from mailhost.u-strasbg.fr (HELO mailhost.u-strasbg.fr) (130.79.200.153) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Sat, 13 Jun 2009 20:29:11 +0000 Received: from baal.u-strasbg.fr (baal.u-strasbg.fr [IPv6:2001:660:2402::41]) by mailhost.u-strasbg.fr (8.14.2/jtpda-5.5pre1) with ESMTP id n5DKT5OR085652 ; Sat, 13 Jun 2009 22:29:05 +0200 (CEST) Received: from mailserver.u-strasbg.fr (ms1.u-strasbg.fr [IPv6:2001:660:2402:d::10]) by baal.u-strasbg.fr (8.14.0/jtpda-5.5pre1) with ESMTP id n5DKT4bP019259 ; Sat, 13 Jun 2009 22:29:05 +0200 (CEST) (envelope-from muller@ics.u-strasbg.fr) Received: from d620muller (lec67-4-82-230-53-140.fbx.proxad.net [82.230.53.140]) (user=mullerp mech=LOGIN) by mailserver.u-strasbg.fr (8.14.3/jtpda-5.5pre1) with ESMTP id n5DKT3uQ013977 (version=TLSv1/SSLv3 cipher=RC4-MD5 bits=128 verify=NO) ; Sat, 13 Jun 2009 22:29:03 +0200 (CEST) (envelope-from muller@ics.u-strasbg.fr) From: "Pierre Muller" To: "'Daniel Jacobowitz'" Cc: References: <001201c9ebb1$96414b10$c2c3e130$@u-strasbg.fr> <20090613150505.GA28157@caradoc.them.org> In-Reply-To: <20090613150505.GA28157@caradoc.them.org> Subject: RE: [RFC] Improve testsuite for poor expect behavior Date: Sat, 13 Jun 2009 20:29:00 -0000 Message-ID: <000001c9ec65$9bf13ca0$d3d3b5e0$@u-strasbg.fr> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2009-06/txt/msg00362.txt.bz2 > -----Message d'origine----- > De=A0: gdb-patches-owner@sourceware.org [mailto:gdb-patches- > owner@sourceware.org] De la part de Daniel Jacobowitz > Envoy=E9=A0: Saturday, June 13, 2009 5:05 PM > =C0=A0: Pierre Muller > Cc=A0: gdb-patches@sourceware.org > Objet=A0: Re: [RFC] Improve testsuite for poor expect behavior >=20 > On Sat, Jun 13, 2009 at 01:00:31AM +0200, Pierre Muller wrote: > > For mingw32, the main problem is that > > there are extra ^M generated in the output. >=20 > Why? ISTR that this is fixed by setting stdout/stderr to binary mode, > but I thought a patch was submitted for this ages ago... I know we're > carrying one in our tree. I don't get this: the patch does not only concern the output from GDB, but also from debuggee executables. Do you mean that we should set stdout/stderr to binary in all testsuite executables too? I am not really sure that running the executables=20 directly would still give the correct output in that case. At least for DJGPP, sending only a newline, will make that all output will overwrite the same line of the console...=20 Anyway, my code only applies to targets explicitly listed.=20=20 =20 > > There is a second aspect, which is mainly a problem of > > the cygwin expect: GDB run inside expect does not believe that > > they are connected to a terminal, which means that queries are > > answered by their default values. > > A large part of the patch below is devoted to adding pattern > > that recognize correctly the cases where a query is answered > automatically. >=20 > I do not like either of these changes to the testsuite, because > they're outright wrong on other platforms. I'd rather fix them in > GDB. They're not limitations of expect, but of the environment in > which GDB is running. Here again, I don't understand your position: I only add new patterns corresponding to output from GDB that only occur if GDB believes that it is not connected to a terminal, why should it have adverse effects on platforms for which this works? =20=20 Pierre