We should include WinSock2.h in modules-ext/map/src to avoid compiling issues on Windows for people who only have the current Windows SDK on their machine or whose $(WindowsSDK_IncludePath) variable points to an SDK more recent than 7.1a.
I've fixed this on a Windows box by simply adding the path to the 7.1a include dir for my build box, i.e., C:\Program Files (x86)\Microsoft SDKs\Windows\v7.1A\Include, in the MAP_dll project properties under VC++ Directories -> Include Directories.
But if we simply add WinSock2.h to the MAP_dll project, then the above fix is not needed and this solution would be valid for all Windows builds. We would need to exclude WinSock2.h from non-Windows builds.
For now, I've added the file WinSock2.h to the Maplib folder of this repo and modified the MAP_dll.vcxproj file to point to it there. This is only a temporary fix for now.
We should include WinSock2.h in modules-ext/map/src to avoid compiling issues on Windows for people who only have the current Windows SDK on their machine or whose $(WindowsSDK_IncludePath) variable points to an SDK more recent than 7.1a.
I've fixed this on a Windows box by simply adding the path to the 7.1a include dir for my build box, i.e., C:\Program Files (x86)\Microsoft SDKs\Windows\v7.1A\Include, in the MAP_dll project properties under VC++ Directories -> Include Directories.
But if we simply add WinSock2.h to the MAP_dll project, then the above fix is not needed and this solution would be valid for all Windows builds. We would need to exclude WinSock2.h from non-Windows builds.