]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
lib: add required Win32 setup definitions in setup-win32.h
authorMarc Hoersken <info@marc-hoersken.de>
Fri, 26 Aug 2022 19:16:47 +0000 (21:16 +0200)
committerMarc Hoersken <info@marc-hoersken.de>
Tue, 6 Sep 2022 17:29:44 +0000 (19:29 +0200)
Assisted-by: Jay Satiro
Reviewed-by: Marcel Raad
Follow up to #9312
Closes #9375

CMake/CurlTests.c
lib/setup-win32.h

index e55e3a62923a914276b3f3ce0848e7fd2b3356c9..0ea7a541f068b4b4bad9f3840ca9372fc66a5c5d 100644 (file)
@@ -539,17 +539,6 @@ main() {
 #ifdef HAVE_WIN32_WINNT
 /* includes start */
 #ifdef WIN32
-/*
- * Don't include unneeded stuff in Windows headers to avoid compiler
- * warnings and macro clashes.
- * Make sure to define this macro before including any Windows headers.
- */
-#  ifndef WIN32_LEAN_AND_MEAN
-#    define WIN32_LEAN_AND_MEAN
-#  endif
-#  ifndef NOGDI
-#    define NOGDI
-#  endif
 #  include "../lib/setup-win32.h"
 #endif
 /* includes end */
index c16928db908bf40f44b62b7aae0ecb8f9475ab04..e54f9d79800660ca53214a63e55cec1445ce989a 100644 (file)
 #  if defined(_UNICODE) && !defined(UNICODE)
 #    define UNICODE
 #  endif
+/*
+ * Don't include unneeded stuff in Windows headers to avoid compiler
+ * warnings and macro clashes.
+ * Make sure to define this macro before including any Windows headers.
+ */
+#  ifndef WIN32_LEAN_AND_MEAN
+#    define WIN32_LEAN_AND_MEAN
+#  endif
+#  ifndef NOGDI
+#    define NOGDI
+#  endif
 #  include <winerror.h>
 #  include <windows.h>
 #  ifdef HAVE_WINSOCK2_H