This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [RFC] Mingw Windows 64-bit gdbserver


On Friday 16 April 2010 17:38:28, Pierre Muller wrote:
>   GDb sources is still a mix:
> 
> > Typo: I meant winsock2.h instead of winsock.h.
> 
> $ grep "include.*<winso" *.h  gdbserver/*.h *.c gdbserver/*.c
> gdb_select.h:#include <winsock2.h>
> serial.h:#include <winsock2.h>
> m32r-rom.c:#include <winsock.h>
> remote-m32r-sdi.c:#include <winsock.h>
> ser-base.c:#include <winsock2.h>
> ser-tcp.c:#include <winsock2.h>
> gdbserver/gdbreplay.c:#include <winsock.h>
> gdbserver/remote-utils.c:#include <winsock.h>
> 
> should all be moved to winsock2.h?

Probably not a real problem as we only activate
Winsock 1:

gdb/
>grep WSAStart *.c -rn
m32r-rom.c:451:      if (WSAStartup (MAKEWORD (1, 1), &wd))
ser-mingw.c:1255:  if (WSAStartup (MAKEWORD (1, 0), &wsa_data) != 0)

gdb/gdbserver/
>grep WSAStart *.c -rn
gdbreplay.c:207:          WSAStartup (MAKEWORD (1, 0), &wsad);
remote-utils.c:288:       WSAStartup (MAKEWORD (1, 0), &wsad);

Presumably winsock2.h is a superset of winsock.h and so we're
likely fine.  Wouldn't hurt to be consistent, moreso since we
include winsock2.h in some headers.

> and -lws2_32 as library?

You mean in gdbserver?  Shouldn't hurt, yeah.

> By the way, do the m32r sources still link correctly currently?

No idea.  There were recent changes to some of those
files though.

-- 
Pedro Alves


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]