From: Zeev Suraski Date: Mon, 26 Apr 1999 19:02:59 +0000 (+0000) Subject: Somehow the rules for the configuration parser/scanners disappeared X-Git-Tag: BEFORE_PHP4_APACHE_MODULE_CHANGE~138 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=48de4ce0dd006fb7fe1f1362f225898fc659d86a;p=php Somehow the rules for the configuration parser/scanners disappeared --- diff --git a/main/configuration-parser.y b/main/configuration-parser.y index 79153c10ee..d5ca601051 100644 --- a/main/configuration-parser.y +++ b/main/configuration-parser.y @@ -347,6 +347,7 @@ static void convert_browscap_pattern(pval *pattern) %token CFG_FALSE %token EXTENSION %token T_ZEND_EXTENSION +%token T_ZEND_EXTENSION_TS %% @@ -378,7 +379,18 @@ statement: php3_dl(&$3,MODULE_PERSISTENT,&dummy); } - | T_ZEND_EXTENSION '=' string { zend_load_extension($3.value.str.val); free($3.value.str.val); } + | T_ZEND_EXTENSION '=' string { +#ifndef ZTS + zend_load_extension($3.value.str.val); +#endif + free($3.value.str.val); + } + | T_ZEND_EXTENSION_TS '=' string { +#ifdef ZTS + zend_load_extension($3.value.str.val); +#endif + free($3.value.str.val); + } | SECTION { if (parsing_mode==PARSING_MODE_BROWSCAP) { pval tmp; diff --git a/main/configuration-scanner.l b/main/configuration-scanner.l index 096a4a8248..709fbbbe64 100644 --- a/main/configuration-scanner.l +++ b/main/configuration-scanner.l @@ -59,6 +59,11 @@ void init_cfg_scanner() return T_ZEND_EXTENSION; } + +"zend_extension_ts" { + return T_ZEND_EXTENSION_TS; +} + [ ]*("true"|"on"|"yes")[ ]* { cfglval->value.str.val = php3_strndup("1",1); cfglval->value.str.len = 1; diff --git a/php4dll.dsp b/php4dll.dsp index e3e4a40b9a..d8d27a8e9c 100644 --- a/php4dll.dsp +++ b/php4dll.dsp @@ -653,6 +653,39 @@ SOURCE=.\win32\wfile.h # Begin Source File SOURCE=".\configuration-parser.y" + +!IF "$(CFG)" == "php4dll - Win32 Debug" + +# Begin Custom Build +InputPath=".\configuration-parser.y" + +BuildCmds= \ + bison --output=configuration-parser.c -v -d -S "C:\Program Files\Cygnus\share\bison.simple" -p cfg configuration-parser.y + +"configuration-parser.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)" + $(BuildCmds) + +"configuration-parser.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)" + $(BuildCmds) +# End Custom Build + +!ELSEIF "$(CFG)" == "php4dll - Win32 Release" + +# Begin Custom Build +InputPath=".\configuration-parser.y" + +BuildCmds= \ + bison --output=configuration-parser.c -v -d -S "C:\Program Files\Cygnus\share\bison.simple" -p cfg configuration-parser.y + +"configuration-parser.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)" + $(BuildCmds) + +"configuration-parser.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)" + $(BuildCmds) +# End Custom Build + +!ENDIF + # End Source File # End Group # Begin Group "Scanners" @@ -661,6 +694,29 @@ SOURCE=".\configuration-parser.y" # Begin Source File SOURCE=".\configuration-scanner.l" + +!IF "$(CFG)" == "php4dll - Win32 Debug" + +# Begin Custom Build +InputPath=".\configuration-scanner.l" + +"configuration-scanner.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)" + flex -i -Pcfg -oconfiguration-scanner.c configuration-scanner.l + +# End Custom Build + +!ELSEIF "$(CFG)" == "php4dll - Win32 Release" + +# Begin Custom Build +InputPath=".\configuration-scanner.l" + +"configuration-scanner.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)" + flex -i -Pcfg -oconfiguration-scanner.c configuration-scanner.l + +# End Custom Build + +!ENDIF + # End Source File # End Group # End Target diff --git a/php4dllts.dsp b/php4dllts.dsp index 4dbe174bd9..8c9da25a1c 100644 --- a/php4dllts.dsp +++ b/php4dllts.dsp @@ -653,6 +653,39 @@ SOURCE=.\win32\wfile.h # Begin Source File SOURCE=".\configuration-parser.y" + +!IF "$(CFG)" == "php4dllts - Win32 Debug_TS" + +# Begin Custom Build +InputPath=".\configuration-parser.y" + +BuildCmds= \ + bison --output=configuration-parser.c -v -d -S "C:\Program Files\Cygnus\share\bison.simple" -p cfg configuration-parser.y + +"configuration-parser.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)" + $(BuildCmds) + +"configuration-parser.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)" + $(BuildCmds) +# End Custom Build + +!ELSEIF "$(CFG)" == "php4dllts - Win32 Release_TS" + +# Begin Custom Build +InputPath=".\configuration-parser.y" + +BuildCmds= \ + bison --output=configuration-parser.c -v -d -S "C:\Program Files\Cygnus\share\bison.simple" -p cfg configuration-parser.y + +"configuration-parser.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)" + $(BuildCmds) + +"configuration-parser.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)" + $(BuildCmds) +# End Custom Build + +!ENDIF + # End Source File # End Group # Begin Group "Scanners" @@ -661,6 +694,29 @@ SOURCE=".\configuration-parser.y" # Begin Source File SOURCE=".\configuration-scanner.l" + +!IF "$(CFG)" == "php4dllts - Win32 Debug_TS" + +# Begin Custom Build +InputPath=".\configuration-scanner.l" + +"configuration-scanner.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)" + flex -i -Pcfg -oconfiguration-scanner.c configuration-scanner.l + +# End Custom Build + +!ELSEIF "$(CFG)" == "php4dllts - Win32 Release_TS" + +# Begin Custom Build +InputPath=".\configuration-scanner.l" + +"configuration-scanner.c" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)" + flex -i -Pcfg -oconfiguration-scanner.c configuration-scanner.l + +# End Custom Build + +!ENDIF + # End Source File # End Group # End Target