cURL
Haxx ad
libcurl

curl's project page on SourceForge.net

Sponsors:
Haxx

cURL > Mailing List > Monthly Index > Single Mail

curl-tracker Archives

[curl:bugs] #1282 Visual Studio 2010 build failed if WINVER >= 0x600 with duplicate define POLLIN for cURL 7.32.0

From: Daniel Stenberg <bagder_at_users.sf.net>
Date: Thu, 26 Sep 2013 20:45:00 +0000

- **status**: open --> pending-needsinfo

---
** [bugs:#1282] Visual Studio 2010 build failed if WINVER >= 0x600 with duplicate define POLLIN for cURL 7.32.0**
**Status:** pending-needsinfo
**Labels:** POLLIN 
**Created:** Tue Sep 24, 2013 09:13 AM UTC by kdekker
**Last Updated:** Thu Sep 26, 2013 02:25 PM UTC
**Owner:** Daniel Stenberg
If no WINVER and/or _WIN32_IWNNT define was set, the Windows platform SDK often defaults to high value, e.g. 0x601 (whoch may probably depend on the Windows version being used, in my case Windows 7).
If WINVER >= 0x600 then winsock2.h includes some defines for WSAPoll(), e.g. POLLIN, POLLPRI, POLLOUT etc. These defines clash with cURL's lib/select.h.
I made a minor change to get the Windows/Visual Studio build working, see diff below:
~~~~~~
diff lib\select.h \obj.WINx64\thirdparty\cURL\curl-7.32.0\lib\select.h
39,40c39
<     !defined(HAVE_POLL_H) && \
<     !defined(_WIN32)
---
>     !defined(HAVE_POLL_H)
~~~~~~
An additional !defined(_WIN32) was added to prevent that lib/select.h defines duplicates. Because cURL does not use WSAPoll at all (see http://daniel.haxx.se/blog/2012/10/10/wsapoll-is-broken/), I think it is safe to omit these defines for Visual Studio. But if this change conflicts with other compiler on Windows, then something else need to be figured out.
---
Sent from sourceforge.net because curl-tracker@cool.haxx.se is subscribed to https://sourceforge.net/p/curl/bugs/
To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/curl/admin/bugs/options.  Or, if this is a mailing list, you can unsubscribe from the mailing list.
Received on 2013-09-26

These mail archives are generated by hypermail.

donate! Page updated May 06, 2013.
web site info

File upload with ASP.NET