#45698 [Asn->WFx]: Doesn't compile with VC6 - Include problem
| From: | pajoye@php.net | Date: | Sun, 03 Aug 2008 13:35:51 +0000 |
| Subject: | #45698 [Asn->WFx]: Doesn't compile with VC6 - Include problem | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-127544@lists.php.net to get a copy of this message | ||
ID: 45698
Updated by: pajoye@php.net
Reported By: Keisial at gmail dot com
-Status: Assigned
+Status: Wont fix
Bug Type: Compile Failure
Operating System: Windows - VC6
PHP Version: 5.3CVS-2008-08-03 (snap)
-Assigned To: stas
+Assigned To: pajoye
New Comment:
Err no.
Please do not commit this patch as it does break VC6 builds now.
Please use the following compilers SDK pairs:
http://wiki.php.net/internals/windows/compiler
http://wiki.php.net/internals/windows/windowssdk
This is what we use for http://snaps.php.net
Previous Comments:
------------------------------------------------------------------------
[2008-08-03 13:25:31] pajoye@php.net
Stas, can you commit the patch please?
------------------------------------------------------------------------
[2008-08-03 12:27:13] derick@php.net
This will probably fix the compile failure that Steph and I were
getting...
------------------------------------------------------------------------
[2008-08-03 12:23:45] Keisial at gmail dot com
Description:
------------
5.3 doesn't compile with VC6. When including winsock2.h at
zend_config.w32.h it includes windows.h which in turn includes winsock
stuff before a SOCKET is defined. Compilation fails with error on
mswsock.h
(This doesn't happen including only those two headers, so some defines
are modifying the defualt behaviour)
Changing the order to include windows.h before winsock2.h fixes it:
--- zend_config.w32.h 2008-07-17 20:33:46.000000000 +0200
+++ zend_config.w32.h 2008-08-03 14:19:56.593750000 +0200
@@ -35,8 +35,8 @@
#ifndef ZEND_INCLUDE_FULL_WINDOWS_HEADERS
#define WIN32_LEAN_AND_MEAN
#endif
-#include <winsock2.h>
#include <windows.h>
+#include <winsock2.h>
#include <float.h>
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=45698&edit=1