From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 31983 invoked by alias); 7 Oct 2011 13:53:28 -0000 Received: (qmail 31911 invoked by uid 22791); 7 Oct 2011 13:53:03 -0000 X-Spam-Check-By: sourceware.org Received: from aquarius.hirmke.de (HELO calimero.vinschen.de) (217.91.18.234) by sourceware.org (qpsmtpd/0.83/v0.83-20-g38e4449) with ESMTP; Fri, 07 Oct 2011 13:52:48 +0000 Received: by calimero.vinschen.de (Postfix, from userid 500) id 16D5C2C00DB; Fri, 7 Oct 2011 15:52:45 +0200 (CEST) Date: Fri, 07 Oct 2011 13:53:00 -0000 From: Corinna Vinschen To: gdb-patches@sourceware.org Subject: Re: [RFA] testsuite: Add a test for passing of environment variables to inferior Message-ID: <20111007135245.GF17583@calimero.vinschen.de> Reply-To: gdb-patches@sourceware.org Mail-Followup-To: gdb-patches@sourceware.org References: <20111004134506.GB24369@calimero.vinschen.de> <000901cc82a4$dfba7cd0$9f2f7670$@muller@ics-cnrs.unistra.fr> <20111004151236.GC15757@calimero.vinschen.de> <003901cc82b0$471e3a00$d55aae00$@muller@ics-cnrs.unistra.fr> <20111005113941.GA13366@calimero.vinschen.de> <004401cc8357$74fd1c00$5ef75400$@muller@ics-cnrs.unistra.fr> <20111005125157.GA24105@calimero.vinschen.de> <20111006145106.GA21790@ednor.casa.cgf.cx> <20111006150256.GA26438@calimero.vinschen.de> <20111007122544.GB9870@ednor.casa.cgf.cx> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20111007122544.GB9870@ednor.casa.cgf.cx> User-Agent: Mutt/1.5.21 (2010-09-15) 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: 2011-10/txt/msg00198.txt.bz2 On Oct 7 08:25, Christopher Faylor wrote: > On Thu, Oct 06, 2011 at 05:02:56PM +0200, Corinna Vinschen wrote: > >On Oct 6 10:51, Christopher Faylor wrote: > >> Why not just check if CW_CVT_ENV_TO_WINENV is defined rather than checking > >> specifically for a version number? Checking arbitrary versions like this > >> should be a last resort. > > > >The CW_foo values are not macros, but enum values. You can't check > >them for being defined. > > > >Possible workaround is to define them twice, once as enum and once > >as macro, just as Linux does or just as some Cygwin headers do, > >for instance : > > > > enum > > { > > IPPROTO_IP = 0, /* Dummy protocol for TCP */ > > IPPROTO_HOPOPTS = 0, /* IPv6 Hop-by-Hop options */ > > [...] > > }; > > > > #define IPPROTO_IP IPPROTO_IP > > #define IPPROTO_HOPOPTS IPPROTO_HOPOPTS > > [...] > > > >If we do that in as well, I can change the test to > >#ifdef CW_CVT_ENV_TO_WINENV. What do you think? > > Ok. Thanks, patch with this change applied. Corinna -- Corinna Vinschen Cygwin Project Co-Leader Red Hat