pajoye                                   Mon, 12 Jul 2010 09:02:27 +0000

Revision: http://svn.php.net/viewvc?view=revision&revision=301178

Log:
- windows support for lemon, 1st shot (some warning in lemon.c but seems to 
work)

Changed paths:
    U   php/php-src/branches/LEMON/win32/build/Makefile
    U   php/php-src/branches/LEMON/win32/build/config.w32

Modified: php/php-src/branches/LEMON/win32/build/Makefile
===================================================================
--- php/php-src/branches/LEMON/win32/build/Makefile     2010-07-12 08:51:41 UTC 
(rev 301177)
+++ php/php-src/branches/LEMON/win32/build/Makefile     2010-07-12 09:02:27 UTC 
(rev 301178)
@@ -26,8 +26,10 @@

 MCFILE=$(BUILD_DIR)\wsyslog.rc

-all: generated_files $(EXT_TARGETS) $(PECL_TARGETS) $(SAPI_TARGETS)
+all: $(BUILD_DIR)\lemon.exe generated_files $(EXT_TARGETS) $(PECL_TARGETS) 
$(SAPI_TARGETS)

+LEMON=$(BUILD_DIR)\lemon.exe
+
 build_dirs: $(BUILD_DIR) $(BUILD_DIRS_SUB)

 !if $(RE2C) == ""
@@ -45,10 +47,10 @@
        type $(PHP_DLL_DEF_SOURCES) > $(BUILD_DIR)\$(PHPDLL).def

 Zend\zend_ini_parser.c Zend\zend_ini_parser.h: Zend\zend_ini_parser.y
-       $(BISON) --output=Zend/zend_ini_parser.c -v -d -p ini_ 
Zend/zend_ini_parser.y
+       $(LEMON) $(LEMON_FLAGS) --output=Zend/zend_ini_parser.c -v -d -p ini_ 
Zend/zend_ini_parser.y

 Zend\zend_language_parser.c Zend\zend_language_parser.h: 
Zend\zend_language_parser.y
-       $(BISON) --output=Zend/zend_language_parser.c -v -d -p zend 
Zend/zend_language_parser.y
+       $(LEMON) $(LEMON_FLAGS) Zend/zend_language_parser.y

 !if $(RE2C) != ""
 Zend\zend_ini_scanner.c: Zend\zend_ini_scanner.l
@@ -97,12 +99,16 @@
        @for %D in (_x $(SAPI_TARGETS)) do @if exist $(BUILD_DIR)\%D @del /F /Q 
$(BUILD_DIR)\%D > NUL
        -...@del /F /Q $(BUILD_DIR)\$(PHPDLL)

-clean: clean-sapi
+clean: clean-sapi clean-lemon
        @echo Cleaning distribution build dirs
        @for %D in (_x $(BUILD_DIRS_SUB)) do @if exist %D @del /F /Q %D\*.* > 
NUL
        -...@del /F /Q $(BUILD_DIR)\*.res $(BUILD_DIR)\*.lib $(BUILD_DIR)\*.ilk 
$(BUILD_DIR)\*.pdb $(BUILD_DIR)\*.exp $(PHPDEF) 
$(BUILD_DIR)\php-$(PHP_VERSION_STRING)-Win32.zip 
$(BUILD_DIR)\pecl-$(PHP_VERSION_STRING)-Win32.zip > NUL
        -rd /s /q $(BUILD_DIR)\php-$(PHP_VERSION_STRING)

+clean-lemon:
+       @echo Cleaning lemon build dirs
+       -...@del $(BUILD_DIR)\lemon.*
+
 clean-pecl:
        @echo Cleaning PECL targets only
        -rd /s /q $(BUILD_DIR)\pecl
@@ -148,6 +154,10 @@
 $(BUILD_DIR)\deplister.exe:    win32\build\deplister.c
        $(CL) /Fo$(BUILD_DIR)\ /Fd$(BUILD_DIR)\ /Fp$(BUILD_DIR)\ 
/FR$(BUILD_DIR) /Fe$(BUILD_DIR)\deplister.exe win32\build\deplister.c 
imagehlp.lib

+
+$(BUILD_DIR)\lemon.exe:        lemon.c
+       $(CL) /Fo$(BUILD_DIR)\ /Fd$(BUILD_DIR)\ /Fp$(BUILD_DIR)\ 
/FR$(BUILD_DIR) /Fe$(BUILD_DIR)\lemon.exe lemon.c
+
 msi-installer: dist
        $(BUILD_DIR)\php.exe ..\php-installer\build-installer.php 
"$(BUILD_DIR)" "$(PHPDLL)" "$(SAPI_TARGETS)" "$(EXT_TARGETS)" "$(PECL_TARGETS)"


Modified: php/php-src/branches/LEMON/win32/build/config.w32
===================================================================
--- php/php-src/branches/LEMON/win32/build/config.w32   2010-07-12 08:51:41 UTC 
(rev 301177)
+++ php/php-src/branches/LEMON/win32/build/config.w32   2010-07-12 09:02:27 UTC 
(rev 301178)
@@ -204,6 +204,9 @@

 if (PHP_ZTS == "yes") {
        ADD_FLAG("CFLAGS", "/D ZTS=1");
+       DEFINE("LEMON_FLAGS", "-c -q D=ZTS");
+} else {
+       DEFINE("LEMON_FLAGS", "-c -q");
 }

 DEFINE("PHP_ZTS_ARCHIVE_POSTFIX", PHP_ZTS == "yes" ? '' : "-nts");

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to