aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorYang Tse <yangsita@gmail.com>2007-11-08 18:13:54 +0000
committerYang Tse <yangsita@gmail.com>2007-11-08 18:13:54 +0000
commit32195c673de46a48457709bd4efa5c63525e1d68 (patch)
tree127f45b0db924c1c56b613c321f3428a880c1254 /include
parentb99a61c5b046d1a9b2c5f2e071233bb9c0458210 (diff)
Define WIN32 when build target is Win32 API.
This also defines it for WinCE even though it is a subset of WIN32.
Diffstat (limited to 'include')
-rw-r--r--include/curl/curl.h14
1 files changed, 8 insertions, 6 deletions
diff --git a/include/curl/curl.h b/include/curl/curl.h
index a29476017..79ea49752 100644
--- a/include/curl/curl.h
+++ b/include/curl/curl.h
@@ -29,6 +29,14 @@
#include "curlver.h" /* the libcurl version defines */
+/*
+ * Define WIN32 when build target is Win32 API
+ */
+
+#if (defined(_WIN32) || defined(__WIN32__)) && !defined(WIN32)
+#define WIN32
+#endif
+
#include <stdio.h>
#include <limits.h>
@@ -41,12 +49,6 @@
# include <time.h>
#endif /* defined (vms) */
-#if defined(_WIN32) && !defined(WIN32)
-/* Chris Lewis mentioned that he doesn't get WIN32 defined, only _WIN32 so we
- make this adjustment to catch this. */
-#define WIN32 1
-#endif
-
#if defined(WIN32) && !defined(_WIN32_WCE) && !defined(__GNUC__) && \
!defined(__CYGWIN__) || defined(__MINGW32__)
#if !(defined(_WINSOCKAPI_) || defined(_WINSOCK_H))