diff options
author | Zeev Suraski <zeev@php.net> | 1999-07-24 16:52:00 +0000 |
---|---|---|
committer | Zeev Suraski <zeev@php.net> | 1999-07-24 16:52:00 +0000 |
commit | 68e32f6ac37eebe70c0ebbbbfaefceeafbaa6d73 (patch) | |
tree | 06c480c4c98160473f8971d676d1b859336d16c2 | |
parent | 24eb90c524e36e9bbdfda0cced94bf239ee026ec (diff) | |
download | php-git-68e32f6ac37eebe70c0ebbbbfaefceeafbaa6d73.tar.gz |
* Make Win32 build work again
* Make error_reporting value prior to the standard initialization be
set so that errors show up
-rw-r--r-- | ext/standard/fsock.c | 2 | ||||
-rw-r--r-- | ext/standard/parsedate.y | 12 | ||||
-rw-r--r-- | main/main.c | 7 | ||||
-rw-r--r-- | php4dll.dsp | 24 | ||||
-rw-r--r-- | php4dllts.dsp | 24 |
5 files changed, 62 insertions, 7 deletions
diff --git a/ext/standard/fsock.c b/ext/standard/fsock.c index ea5968e043..227e606c5d 100644 --- a/ext/standard/fsock.c +++ b/ext/standard/fsock.c @@ -248,7 +248,7 @@ static void _php3_fsockopen(INTERNAL_FUNCTION_PARAMETERS, int persistent) { switch(arg_count) { case 5: convert_to_double(args[4]); - conv = (unsigned long) args[4]->value.dval * 1000000.0; + conv = (unsigned long) (args[4]->value.dval * 1000000.0); timeout.tv_sec = conv / 1000000; timeout.tv_usec = conv % 1000000; /* fall-through */ diff --git a/ext/standard/parsedate.y b/ext/standard/parsedate.y index df75728bb0..6552c517a2 100644 --- a/ext/standard/parsedate.y +++ b/ext/standard/parsedate.y @@ -24,6 +24,10 @@ # include "php_config.h" #endif +#if WIN32||WINNT +#include <malloc.h> +#endif + #include <stdio.h> #include <sys/types.h> #include <time.h> @@ -41,10 +45,12 @@ #include <alloca.h> #endif -#ifndef HAVE_TM_ZONE -#ifndef _TIMEZONE +#if WIN32||WINNT +#include <time.h> +#else +# if !defined(HAVE_TM_ZONE) && !defined(_TIMEZONE) extern time_t timezone; -#endif +# endif #endif #define yylhs date_yylhs diff --git a/main/main.c b/main/main.c index 59d1a54b37..361a3c6853 100644 --- a/main/main.c +++ b/main/main.c @@ -768,11 +768,10 @@ int php_module_startup(sapi_module_struct *sf) sapi_globals_struct *sapi_globals = ts_resource(sapi_globals_id); #endif #if (WIN32|WINNT) && !(USE_SAPI) - WORD wVersionRequested; + WORD wVersionRequested = MAKEWORD(2, 0); WSADATA wsaData; - - wVersionRequested = MAKEWORD(2, 0); #endif + ELS_FETCH(); SG(server_context) = NULL; SG(request_info).request_method = NULL; @@ -782,6 +781,8 @@ int php_module_startup(sapi_module_struct *sf) return SUCCESS; } + EG(error_reporting) = E_ALL & ~E_NOTICE; + sapi_module = *sf; zend_output_startup(); diff --git a/php4dll.dsp b/php4dll.dsp index 88e260aa56..abc95a1fc7 100644 --- a/php4dll.dsp +++ b/php4dll.dsp @@ -363,6 +363,10 @@ SOURCE=.\ext\standard\pageinfo.c # End Source File
# Begin Source File
+SOURCE=.\ext\standard\parsedate.c
+# End Source File
+# Begin Source File
+
SOURCE=.\ext\pcre\php_pcre.c
# End Source File
# Begin Source File
@@ -739,6 +743,26 @@ BuildCmds= \ !ENDIF
# End Source File
+# Begin Source File
+
+SOURCE=.\ext\standard\parsedate.y
+
+!IF "$(CFG)" == "php4dll - Win32 Debug"
+
+# Begin Custom Build
+InputPath=.\ext\standard\parsedate.y
+
+"ext\standard\parsedate.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+ cd ext\standard
+ bison --output=parsedate.c -v -d -S "C:\Program Files\Cygnus\share\bison.simple" parsedate.y
+
+# End Custom Build
+
+!ELSEIF "$(CFG)" == "php4dll - Win32 Release"
+
+!ENDIF
+
+# End Source File
# End Group
# Begin Group "Scanners"
diff --git a/php4dllts.dsp b/php4dllts.dsp index fe93f84042..0925f76d9e 100644 --- a/php4dllts.dsp +++ b/php4dllts.dsp @@ -371,6 +371,10 @@ SOURCE=.\ext\standard\pageinfo.c # End Source File
# Begin Source File
+SOURCE=.\ext\standard\parsedate.c
+# End Source File
+# Begin Source File
+
SOURCE=.\ext\pcre\php_pcre.c
# End Source File
# Begin Source File
@@ -755,6 +759,26 @@ BuildCmds= \ !ENDIF
# End Source File
+# Begin Source File
+
+SOURCE=.\ext\standard\parsedate.y
+
+!IF "$(CFG)" == "php4dllts - Win32 Debug_TS"
+
+# Begin Custom Build
+InputPath=.\ext\standard\parsedate.y
+
+"ext\standard\parsedate.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+ cd ext\standard
+ bison --output=parsedate.c -v -d -S "C:\Program Files\Cygnus\share\bison.simple" parsedate.y
+
+# End Custom Build
+
+!ELSEIF "$(CFG)" == "php4dllts - Win32 Release_TS"
+
+!ENDIF
+
+# End Source File
# End Group
# Begin Group "Scanners"
|