From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 5590 invoked by alias); 5 Apr 2005 18:07:24 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 635 invoked from network); 5 Apr 2005 18:05:41 -0000 Received: from unknown (HELO mail.codesourcery.com) (65.74.133.9) by sourceware.org with SMTP; 5 Apr 2005 18:05:41 -0000 Received: (qmail 30741 invoked from network); 5 Apr 2005 18:05:40 -0000 Received: from localhost (HELO ?192.168.0.5?) (mitchell@127.0.0.1) by mail.codesourcery.com with SMTP; 5 Apr 2005 18:05:40 -0000 Message-ID: <4252D364.7050304@codesourcery.com> Date: Tue, 05 Apr 2005 18:07:00 -0000 From: Mark Mitchell Organization: CodeSourcery, LLC User-Agent: Mozilla Thunderbird 0.9 (Windows/20041103) MIME-Version: 1.0 To: gdb-patches@sources.redhat.com CC: Mark Kettenis Subject: Follow-up on patch to ser-tcp.c Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2005-04/txt/msg00050.txt.bz2 Mark -- A while back, I posted a patch to change ser-tcp.c to support Windows, here: http://sources.redhat.com/ml/gdb-patches/2005-03/msg00331.html You had some objections: 1. The configury change to link with -lws2_23 on Windows. 2. The use of #ifdef WINAPI. 3. The asymmetry I introduced by adding the "read_prim" member to "struct serial" without a corresponding "write_prim" member. 4. Changes to support differences between BSD and Windows socket APIs. 5. Modifications to strerror. I don't see a way around (1). The question is really not whether the library is available; the question is whether we should use it. On MinGW, we should; on Cygwin, we should not. The impact of (2) can be mitigated by using __MINGW32__ instead of WINAPI. That will avoid the defs.h change, and localize the changes to the actual conditional code. In my local version of the patch, I've corrected (3); the symmetry is now complete. I've also mitigated (4), in that I've determined that send/recv should work fine on all targets. That means that we don't need an #ifdef to decide whether to use "read" or "recv"; we can just always use "recv", as that function is available both on Windows and elsewhere. I can drop (5) from the patch, and we can come back to that later. With the set of changes described here, would you be willing to consider the patch again? If so, I will post the modified version. Thanks, -- Mark Mitchell CodeSourcery, LLC mark@codesourcery.com (916) 791-8304