This is the mail archive of the 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: Problem with COM1 port from with GDB 5.3 under Cygwin 1.5.3-1

> Date: Tue, 23 Sep 2003 13:07:32 -0600
> From: Creighton MacDonnell <>
> This patch avoids the Cygwin 1.5.* problem with "com*" port names, while 
> still allowing "com*" names to be used in GDB scripts (they get 
> translated to "/dev/com?"), and also allows "/dev/ttyS*" and "/dev/com*" 
> device names to be used.
> --- ./gdb/rdi-share/unixcomm.c~    2002-06-08 14:34:41.000000000 -0600
> +++ ./gdb/rdi-share/unixcomm.c    2003-09-23 12:12:43.703125000 -0600
> @@ -96,7 +96,15 @@
>  #define PARPORT2   "/dev/par1"
>  #endif
> -#if defined(_WIN32) || defined (__CYGWIN__)
> +#if defined (__CYGWIN__)
> +#define SERIAL_PREFIX "/dev/com"
> +#define SERPORT1   "/dev/com1"
> +#define SERPORT2   "/dev/com2"
> +#define PARPORT1   "lpt1"
> +#define PARPORT2   "lpt2"
> +#endif

If Cygwin wants /dev/com1 instead of com1, are you sure it won't want
/dev/lpt1 instead of lpt1 as well?

Anyway, is this a Cygwin bug or what?  IIRC, Windows supports both
com1 and /dev/com1, so why doesn't Cygwin do that as well?

Also, what happens with versions of Cygwin other than 1.5.x?  Could
they be broken by this change?

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