Re: Version 1.8.1 does not compile on Cygwin 1.7.14
- From
Jonathan Nieder <jrnieder@gmail.com>
- Date
- Jan 20, 2013, 10:10 UTC
- Message-ID
- <20130120101007.GD16339@elie.Belkin>
- In-Reply-To
- <50F5A435.5090408@ramsay1.demon.co.uk>
Ramsay Jones wrote:
Show 11 quoted lines
> --- a/git-compat-util.h > +++ b/git-compat-util.h > @@ -85,12 +85,6 @@ > #define _NETBSD_SOURCE 1 > #define _SGI_SOURCE 1 > > -#ifdef WIN32 /* Both MinGW and MSVC */ > -#define WIN32_LEAN_AND_MEAN /* stops windows.h including winsock.h */ > -#include <winsock2.h> > -#include <windows.h> > -#endif
So, do I understand correctly that the above conditional should be something like
#if defined(WIN32) && !defined(__CYGWIN__)
to allow dropping the CYGWIN_V15_WIN32API setting?
"defined(WIN32)" is used throughout git to mean "win32 and not cygwin", so if I understand correctly we would either need to do
#if defined(WIN32) && defined(__CYGWIN__) # undef WIN32 #endif
or define a new GIT_WIN32 (name is just a placeholder) macro to use consistently in its stead.
Thanks for investigating. Jonathan