From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 24860 invoked by alias); 4 Feb 2010 00:44:51 -0000 Received: (qmail 24851 invoked by uid 22791); 4 Feb 2010 00:44:50 -0000 X-SWARE-Spam-Status: No, hits=-1.9 required=5.0 tests=AWL,BAYES_00,SARE_MSGID_LONG40,SPF_HELO_PASS,SPF_PASS X-Spam-Check-By: sourceware.org Received: from smtp-out.google.com (HELO smtp-out.google.com) (216.239.44.51) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 04 Feb 2010 00:44:46 +0000 Received: from spaceape9.eur.corp.google.com (spaceape9.eur.corp.google.com [172.28.16.143]) by smtp-out.google.com with ESMTP id o140ii16004603 for ; Wed, 3 Feb 2010 16:44:44 -0800 Received: from ewy22 (ewy22.prod.google.com [10.241.103.22]) by spaceape9.eur.corp.google.com with ESMTP id o140ihvN019891 for ; Wed, 3 Feb 2010 16:44:43 -0800 Received: by ewy22 with SMTP id 22so72140ewy.34 for ; Wed, 03 Feb 2010 16:44:43 -0800 (PST) MIME-Version: 1.0 Received: by 10.216.89.195 with SMTP id c45mr224303wef.38.1265244282925; Wed, 03 Feb 2010 16:44:42 -0800 (PST) In-Reply-To: <4B6A16F1.7050405@vmware.com> References: <20100204002516.DF79F84414@ruffy.mtv.corp.google.com> <4B6A16F1.7050405@vmware.com> Date: Thu, 04 Feb 2010 00:44:00 -0000 Message-ID: Subject: Re: [patch] gdb.exp (INTERNAL_GDBFLAGS): Don't override value provided by user. From: Doug Evans To: Michael Snyder Cc: "gdb-patches@sourceware.org" Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-System-Of-Record: true X-IsSubscribed: yes 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: 2010-02/txt/msg00099.txt.bz2 On Wed, Feb 3, 2010 at 4:38 PM, Michael Snyder wrote: > Doug Evans wrote: >> >> Hi. >> >> I will check this in tomorrow if there are no objections. > > How will this affect me? Previously INTERNAL_GDBFLAGS was always set to "-nw -nx". With the patch it is only set to that if it hasn't already been set (e.g. by the user when starting dejagnu, e.g. with make check RUNTESTFLAGS=3DINTERNAL_GDBFLAGS=3Dmumble). I'd expect therefore that no one is currently running dejagnu and setting INTERNAL_GDBFLAGS. Therefore it shouldn't affect you. >> It is useful to run the testsuite on the installed gdb. >> e.g. make check RUNTESTFLAGS=3DGDB=3D/usr/bin/gdb >> >> When testing the installed gdb one would like to test exactly what the >> user runs. =A0For environments that have a system.gdbinit (gdb was >> configured >> with --with-system-gdbinit) that means using the installed system.gdbinit >> and not anything from the source/build tree. >> In order to do this one either needs to not pass "-nx" when dejagnu star= ts >> gdb >> or pass "-x /path/to/system.gdbinit" in addition to -nx. >> I like the former as it's closer to what the user does. >> >> There is also the issue of not loading ~/.gdbinit when running the >> testsuite, but can be solved by pointing $HOME at a directory without >> a .gdbinit when running the testsuite. >> >> [-nx also skips loading of $pwd/.gdbinit, but the testsuite build >> directory >> generally doesn't have one and that's good enough for me for now] >> >> 2010-02-03 =A0Doug Evans =A0 >> >> =A0 =A0 =A0 =A0* gdb.exp (INTERNAL_GDBFLAGS): Don't override value provi= ded by >> user. >> >> Index: gdb.exp >> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D >> RCS file: /cvs/src/src/gdb/testsuite/lib/gdb.exp,v >> retrieving revision 1.135 >> diff -u -p -r1.135 gdb.exp >> --- gdb.exp =A0 =A0 14 Jan 2010 21:12:00 -0000 =A0 =A0 =A01.135 >> +++ gdb.exp =A0 =A0 4 Feb 2010 00:15:25 -0000 >> @@ -54,7 +54,10 @@ if ![info exists GDBFLAGS] { >> =A0verbose "using GDBFLAGS =3D $GDBFLAGS" 2 >> =A0=A0# INTERNAL_GDBFLAGS contains flags that the testsuite requires. >> -set INTERNAL_GDBFLAGS "-nw -nx" >> +global INTERNAL_GDBFLAGS >> +if ![info exists INTERNAL_GDBFLAGS] { >> + =A0 =A0set INTERNAL_GDBFLAGS "-nw -nx" >> +} >> =A0=A0# The variable gdb_prompt is a regexp which matches the gdb prompt. >> =A0# Set it if it is not already set. > >