From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 21158 invoked by alias); 13 Aug 2013 08:23:14 -0000 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 Received: (qmail 21144 invoked by uid 89); 13 Aug 2013 08:23:14 -0000 X-Spam-SWARE-Status: No, score=-1.8 required=5.0 tests=AWL,BAYES_00,KHOP_THREADED,MSGID_MULTIPLE_AT autolearn=no version=3.3.2 Received: from mailhost.u-strasbg.fr (HELO mailhost.u-strasbg.fr) (130.79.201.45) by sourceware.org (qpsmtpd/0.84/v0.84-167-ge50287c) with ESMTP; Tue, 13 Aug 2013 08:23:12 +0000 Received: from md13.u-strasbg.fr (md13.u-strasbg.fr [130.79.200.248]) by mailhost.u-strasbg.fr (8.14.3/jtpda-5.5pre1) with ESMTP id r7D8N4eM022265 ; Tue, 13 Aug 2013 10:23:04 +0200 (CEST) (envelope-from pierre.muller@ics-cnrs.unistra.fr) Received: from ms12.u-strasbg.fr (ms12.u-strasbg.fr [130.79.204.112]) by md13.u-strasbg.fr (8.14.3/jtpda-5.5pre1) with ESMTP id r7D8N4qa032123 ; Tue, 13 Aug 2013 10:23:04 +0200 (envelope-from pierre.muller@ics-cnrs.unistra.fr) Received: from E6510Muller (gw-ics.u-strasbg.fr [130.79.210.225]) (Authenticated sender: mullerp) by ms12.u-strasbg.fr (Postfix) with ESMTPSA id 23CE71FD92; Tue, 13 Aug 2013 10:23:03 +0200 (CEST) From: "Pierre Muller" To: "'Yao Qi'" Cc: References: <83txjdxtpd.fsf@gnu.org> <51F786CB.3020700@codesourcery.com> <83a9l4xdst.fsf@gnu.org> <51FA137B.6070207@codesourcery.com> <20130803045452.GA997@ednor.casa.cgf.cx> <51FE1493.9070707@codesourcery.com> <20130805044122.GA1825@ednor.casa.cgf.cx> <51FF4483.5000102@codesourcery.com> <20130806020839.GA3362@ednor.casa.cgf.cx> <520067CB.4000300@codesourcery.com> <20130808051114.GA1553@ednor.casa.cgf.cx> <000301ce9408$d51ed560$7f5c8020$@muller@ics-cnrs.unistra.fr> <5209EA1F.5040709@codesourcery.com> In-Reply-To: <5209EA1F.5040709@codesourcery.com> Subject: RE: [PATCH 1/3] Detect GDB is in cygwin Date: Tue, 13 Aug 2013 08:23:00 -0000 Message-ID: <004001ce97fe$554b2b00$ffe18100$@muller@ics-cnrs.unistra.fr> MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-SW-Source: 2013-08/txt/msg00331.txt.bz2 > -----Message d'origine----- > De : gdb-patches-owner@sourceware.org [mailto:gdb-patches- > owner@sourceware.org] De la part de Yao Qi > Envoy=C3=A9 : mardi 13 ao=C3=BBt 2013 10:11 > =C3=80 : Pierre Muller > Cc : gdb-patches@sourceware.org > Objet : Re: [PATCH 1/3] Detect GDB is in cygwin >=20 > On 08/08/2013 03:28 PM, Pierre Muller wrote: > > Without mintty (running Cygwin bash directly), I do get a > FILE_TYPE_CHAR, > > and a second check by calling GetConsoleMode with the same handle > > allows to verify that it is indeed a Windows OS Console handle. > > > > I think that there is indeed no good way to know if we are using > > a non-interactive pipe... > > As the primary purpose of the patch was to allow better results for = the > > testsuite > > for mingw builds, I think that the idea > > of adding a > > "maint set testsuite-mode on/off" > > command that could be > > automatically added to > > INTERNAL_GDBFLAGS as "-iex {maint set testsuite-mode on}" > > would be a simpler approach. > > It would guaranty that we do not change existing behavior for > > interactive GDB use and should solve the problem about ^M^M patterns th= at > > lead to lots of failures when testing mingw builds. > > As I explained earlier, this changes are also required if you want > > to run the testsuite on msys terminal. > > > > Should I prepare a RFC? > > >=20 > Pierre, > Yes, I think so, but before you post it, we have to coordinate on this. > Two people (you and I) post the similar-but-different patches may > confuse maintainers and doesn't help on review and approval on any > of them. There are some issues related to mingw and cygwin, and we > (you and I) are working on some of them, with different focus. If you > don't mind, I'll post my patches again, a fresh version, V4, and > hopefully maintainers can approve them this time. In the review of V3, > all the questions were addressed, AFAIK, but no one approved it > explicitly. > > Then, you can prepare your RFC, and I am happy to help (review and > test). Is it OK to you? OK, this is fine with me.=20 > > One question about this new command that I had in mind > > was about the scope of this command. > > Should I put it inside mingw-hdep.c code and restrict it to > > mingw builds, or should I introduce that command globally, > > the posix-tdep.c version would be an empty function for now, > > but could be useful (?) later. >=20 > I prefer the former one. =20=20 =20 > > The advantage of the second approach is that we could add > > the "-iex {maint set testsuite-mode on}" unconditionally in gdb.exp, > > but that might seem like a weak argument... >=20 > You can modify your board file or build_dir/gdb/testsuite/site.exp to > append the option to GDBFLAGS. This is a tricky area for a newcomer to understand, thus I would really like to get something that would automatically use that new command. In the case we decide to restrict this command to GDB executables built to run as mingw programs, I would like gdb.exp to detect = the host settings correctly and add "-iex {maint set testsuite-mode on}" to INTERNAL_GDBFLAGS. But let's first finalize your patch. Please send your V4, I will wait. Pierre Muller