From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 10664 invoked by alias); 12 Oct 2007 16:11:41 -0000 Received: (qmail 10636 invoked by uid 22791); 12 Oct 2007 16:11:39 -0000 X-Spam-Check-By: sourceware.org Received: from rock.gnat.com (HELO rock.gnat.com) (205.232.38.15) by sourceware.org (qpsmtpd/0.31) with ESMTP; Fri, 12 Oct 2007 16:11:37 +0000 Received: from localhost (localhost.localdomain [127.0.0.1]) by filtered-rock.gnat.com (Postfix) with ESMTP id 89E071E6B4C; Fri, 12 Oct 2007 12:11:35 -0400 (EDT) Received: from rock.gnat.com ([127.0.0.1]) by localhost (rock.gnat.com [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 97zOEmxY3+nb; Fri, 12 Oct 2007 12:11:35 -0400 (EDT) Received: from joel.gnat.com (localhost.localdomain [127.0.0.1]) by rock.gnat.com (Postfix) with ESMTP id 55CC01E6AFE; Fri, 12 Oct 2007 12:11:35 -0400 (EDT) Received: by joel.gnat.com (Postfix, from userid 1000) id CFC13E7B58; Fri, 12 Oct 2007 09:11:32 -0700 (PDT) Date: Fri, 12 Oct 2007 16:11:00 -0000 From: Joel Brobecker To: Eli Zaretskii Cc: Daniel Jacobowitz , Kai.Tietz@onevision.com, gdb@sourceware.org Subject: Re: Support of gdb for Windows 64 native systems Message-ID: <20071012161132.GE4044@adacore.com> References: <20071011142348.GA18239@caradoc.them.org> <20071011145549.GA19918@caradoc.them.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.2.2i Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2007-10/txt/msg00083.txt.bz2 > Actually, wouldn't it be better to separate the two completely? That > should avoid a lot of ugly ifdefs, and make each native backend much > cleaner, I think. The issue with that is that we'll end up duplicating a bit of code. In our merge, I counted 5 instances of "ifdef/ifndef __MINGW32__ in total, all of them in win32-nat.c: - One to define MAXPATHLEN: Should really be done in a proper way, so should go away - One to avoid the #include : Should also be done using HAVE_SYS_PROCFS_H, so should also go away - 3 #ifdef __MINGW32__ in create_inferior to replace unix-style IO handling with Windows-style IO handling. Can we call functions like GetStdHandle from the cygwin compiler, or do we need the MinGW headers for that? Perhaps the mingw code could also work with cygwin? The rest seems to be in i386-win32-tdep.c which is a separate file. -- Joel