From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 18132 invoked by alias); 14 Oct 2004 18:53:37 -0000 Mailing-List: contact gdb-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 18106 invoked from network); 14 Oct 2004 18:53:35 -0000 Received: from unknown (HELO mx1.redhat.com) (66.187.233.31) by sourceware.org with SMTP; 14 Oct 2004 18:53:35 -0000 Received: from int-mx1.corp.redhat.com (int-mx1.corp.redhat.com [172.16.52.254]) by mx1.redhat.com (8.12.11/8.12.10) with ESMTP id i9EIrZwX016354 for ; Thu, 14 Oct 2004 14:53:35 -0400 Received: from localhost.redhat.com (porkchop.devel.redhat.com [172.16.58.2]) by int-mx1.corp.redhat.com (8.11.6/8.11.6) with ESMTP id i9EIrYr20840; Thu, 14 Oct 2004 14:53:34 -0400 Received: from gnu.org (localhost [127.0.0.1]) by localhost.redhat.com (Postfix) with ESMTP id 435F728CF; Thu, 14 Oct 2004 14:53:29 -0400 (EDT) Message-ID: <416ECB29.4050201@gnu.org> Date: Thu, 14 Oct 2004 21:23:00 -0000 From: Andrew Cagney User-Agent: Mozilla/5.0 (X11; U; NetBSD macppc; en-GB; rv:1.4.1) Gecko/20041009 MIME-Version: 1.0 To: "'Bob Rossi'" Cc: Eli Zaretskii , gdb@sources.redhat.com Subject: Re: probing GDB for MI versions References: <20041007145511.GA14573@white> <200410071614.MAA19648@smtp.ott.qnx.com> <20041007224230.GA15177@white> <01c4ad12$Blat.v2.2.2$1796ec80@zahav.net.il> <20041009002901.GB16824@white> <20041013003135.GA22087@white> <01c4b0df$Blat.v2.2.2$e933d3e0@zahav.net.il> <20041013121412.GA22696@white> <01c4b163$Blat.v2.2.2$7d934a60@zahav.net.il> <20041014153720.GA24199@white> In-Reply-To: <20041014153720.GA24199@white> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2004-10/txt/msg00317.txt.bz2 >>> Yes, but Andrew just told you that GDB will most probably support at >>> most 2 MI versions: the latest one and the one before that. So >>> printing only the last version is okay, because if that version is not >>> supported by your front end, you need only to check the previous >>> version. Isn't that good enough? >>> >>> (Even if GDB does support more than 2 MI versions, you could still >>> probe smaller versions until you either (1) find one that is okay with >>> your front end, or (2) get GDB to fail because the MI version you >>> requested is not supported. Yes, it's good enough. Either: - GDB is started with -i=mi; gdb reports its version (if anything I'd be relying on the GDB and not the MI version); your code adjusts - GDB is started with -i=miX; gdb either barfs or soldiers on; your code adjusts Andrew