pajoye                                   Tue, 14 Dec 2010 02:55:26 +0000

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

Log:
- add nmake install-sdk (create the devel package) and related sub rules

Changed paths:
    U   php/php-src/branches/PHP_5_3/win32/build/Makefile
    U   php/php-src/branches/PHP_5_3/win32/build/confutils.js
    U   php/php-src/trunk/win32/build/Makefile
    U   php/php-src/trunk/win32/build/confutils.js

Modified: php/php-src/branches/PHP_5_3/win32/build/Makefile
===================================================================
--- php/php-src/branches/PHP_5_3/win32/build/Makefile	2010-12-14 01:48:31 UTC (rev 306355)
+++ php/php-src/branches/PHP_5_3/win32/build/Makefile	2010-12-14 02:55:26 UTC (rev 306356)
@@ -25,10 +25,12 @@
 PHP_BUILD=$(PHP_BUILD)

 MCFILE=$(BUILD_DIR)\wsyslog.rc
+BUILD_DIR_DEV_NAME=php-$(PHP_VERSION_STRING)-devel-$(PHP_COMPILER_SHORT)-$(PHP_ARCHITECTURE)
+BUILD_DIR_DEV=$(BUILD_DIR)\$(BUILD_DIR_DEV_NAME)

 all: generated_files $(EXT_TARGETS) $(PECL_TARGETS) $(SAPI_TARGETS)

-build_dirs: $(BUILD_DIR) $(BUILD_DIRS_SUB)
+build_dirs: $(BUILD_DIR) $(BUILD_DIRS_SUB) $(BUILD_DIR_DEV)

 !if $(RE2C) == ""
 generated_files: build_dirs Zend\zend_ini_parser.c \
@@ -85,10 +87,11 @@

 $(BUILD_DIR)\$(PHPLIB): $(BUILD_DIR)\$(PHPDLL)

-$(BUILD_DIR) $(BUILD_DIRS_SUB):
+$(BUILD_DIR) $(BUILD_DIRS_SUB) $(BUILD_DIR_DEV):
 	@echo Recreating build dirs
 	@if not exist $(BUILD_DIR) mkdir $(BUILD_DIR)
 	@for %D in ($(BUILD_DIRS_SUB)) do @if not exist %D @mkdir %D > NUL
+	@if not exist $(BUILD_DIR_DEV) @mkdir $(BUILD_DIR_DEV) > NUL

 clean-sapi:
 	@echo Cleaning SAPI
@@ -140,10 +143,13 @@
 	cd ..\..
 	cd $(BUILD_DIR)
 	-$(ZIP) -9 -q php-debug-pack-$(PHP_VERSION_STRING)$(PHP_ZTS_ARCHIVE_POSTFIX)-Win32-$(PHP_COMPILER_SHORT)-$(PHP_ARCHITECTURE).zip *.pdb
+	cd
+	cd
+	-$(ZIP) -9 -q -r php-devel-pack-$(PHP_VERSION_STRING)$(PHP_ZTS_ARCHIVE_POSTFIX)-Win32-$(PHP_COMPILER_SHORT)-$(PHP_ARCHITECTURE).zip $(BUILD_DIR_DEV_NAME)
 	cd ..\..

 dist: all build-dist
-snap: build-snap build-dist
+snap: build-devel build-lib build-snap build-dist

 $(BUILD_DIR)\deplister.exe:	win32\build\deplister.c
 	$(PHP_CL) /Fo$(BUILD_DIR)\ /Fd$(BUILD_DIR)\ /Fp$(BUILD_DIR)\ /FR$(BUILD_DIR) /Fe$(BUILD_DIR)\deplister.exe win32\build\deplister.c imagehlp.lib
@@ -152,24 +158,27 @@
 	$(BUILD_DIR)\php.exe ..\php-installer\build-installer.php "$(BUILD_DIR)" "$(PHPDLL)" "$(SAPI_TARGETS)" "$(EXT_TARGETS)" "$(PECL_TARGETS)"

 # need to redirect, since INSTALL is a file in the root...
-install: really-install install-devel install-lib
+install: really-install install-sdk

-install-lib:
-	@if not exist $(PHP_PREFIX)\lib mkdir $(PHP_PREFIX)\lib >nul
-	@copy $(BUILD_DIR)\$(PHPLIB) $(PHP_PREFIX)\lib /y >nul
+build-lib:
+	@if not exist $(BUILD_DIR_DEV)\lib mkdir $(BUILD_DIR_DEV)\lib >nul
+	@copy $(BUILD_DIR)\$(PHPLIB) $(BUILD_DIR_DEV)\lib /y >nul

-install-devel: install-headers
-	@if not exist $(PHP_PREFIX)\script mkdir $(PHP_PREFIX)\script >nul
-	@if not exist $(PHP_PREFIX)\build mkdir $(PHP_PREFIX)\build >nul
-	@copy win32\build\confutils.js $(PHP_PREFIX)\script\ /y >nul
-	@copy win32\build\configure.tail $(PHP_PREFIX)\script\ /y >nul
-	@copy win32\build\config.w32.phpize.in $(PHP_PREFIX)\script\ /y >nul
-	@copy win32\build\Makefile.phpize $(PHP_PREFIX)\script\ /y >nul
-	@copy win32\build\phpize.bat $(PHP_PREFIX)\ /y >nul
-	@copy win32\build\template.rc $(PHP_PREFIX)\build\ /y >nul
-	@copy $(BUILD_DIR)\devel\config.phpize.js $(PHP_PREFIX)\script\ /y >nul
-	@copy $(BUILD_DIR)\devel\phpize.js $(PHP_PREFIX)\script\ /y >nul
+build-devel: build-headers build-lib
+	@if not exist $(BUILD_DIR_DEV)\script mkdir $(BUILD_DIR_DEV)\script >nul
+	@if not exist $(BUILD_DIR_DEV)\build mkdir $(BUILD_DIR_DEV)\build >nul
+	@copy win32\build\confutils.js $(BUILD_DIR_DEV)\script\ /y >nul
+	@copy win32\build\configure.tail $(BUILD_DIR_DEV)\script\ /y >nul
+	@copy win32\build\config.w32.phpize.in $(BUILD_DIR_DEV)\script\ /y >nul
+	@copy win32\build\Makefile.phpize $(BUILD_DIR_DEV)\script\ /y >nul
+	@copy win32\build\phpize.bat $(BUILD_DIR_DEV)\ /y >nul
+	@copy win32\build\template.rc $(BUILD_DIR_DEV)\build\ /y >nul
+	@copy $(BUILD_DIR)\devel\config.phpize.js $(BUILD_DIR_DEV)\script\ /y >nul
+	@copy $(BUILD_DIR)\devel\phpize.js $(BUILD_DIR_DEV)\script\ /y >nul

+install-sdk: build-devel
+	@xcopy /Q /Y /E /I $(BUILD_DIR_DEV)\* $(PHP_PREFIX)\SDK
+
 really-install:
 	@if not exist $(PHP_PREFIX) mkdir $(PHP_PREFIX)
 	@echo Installing files under $(PHP_PREFIX)

Modified: php/php-src/branches/PHP_5_3/win32/build/confutils.js
===================================================================
--- php/php-src/branches/PHP_5_3/win32/build/confutils.js	2010-12-14 01:48:31 UTC (rev 306355)
+++ php/php-src/branches/PHP_5_3/win32/build/confutils.js	2010-12-14 02:55:26 UTC (rev 306356)
@@ -1720,17 +1720,17 @@

 	MF.Write(TF.ReadAll());

-	MF.WriteLine("install-headers:");
-	MF.WriteLine("	@if not exist $(PHP_PREFIX)\\include mkdir $(PHP_PREFIX)\\include >nul");
-	MF.WriteLine("	@for %D in ($(INSTALL_HEADERS_DIR)) do @if not exist $(PHP_PREFIX)\\include\\%D mkdir $(PHP_PREFIX)\\include\\%D >nul");
+	MF.WriteLine("build-headers:");
+	MF.WriteLine("	@if not exist $(BUILD_DIR_DEV)\\include mkdir $(BUILD_DIR_DEV)\\include >nul");
+	MF.WriteLine("	@for %D in ($(INSTALL_HEADERS_DIR)) do @if not exist $(BUILD_DIR_DEV)\\include\\%D mkdir $(BUILD_DIR_DEV)\\include\\%D >nul");
 	for (i in headers_install) {
 		if (headers_install[i][2] != "") {
-				MF.WriteLine("	@if not exist $(PHP_PREFIX)\\include\\" + headers_install[i][2] + " mkdir $(PHP_PREFIX)\\include\\" +
+				MF.WriteLine("	@if not exist $(BUILD_DIR_DEV)\\include\\" + headers_install[i][2] + " mkdir $(BUILD_DIR_DEV)\\include\\" +
 												headers_install[i][2] + ">nul");
-				MF.WriteLine("	@copy " + headers_install[i][0] + " " + "$(PHP_PREFIX)\\include\\" + headers_install[i][2] + " /y >nul");
+				MF.WriteLine("	@copy " + headers_install[i][0] + " " + "$(BUILD_DIR_DEV)\\include\\" + headers_install[i][2] + " /y >nul");
 		}
 	}
-	MF.WriteLine("	@for %D in ($(INSTALL_HEADERS_DIR)) do @copy %D*.h $(PHP_PREFIX)\\include\\%D /y >nul");
+	MF.WriteLine("	@for %D in ($(INSTALL_HEADERS_DIR)) do @copy %D*.h $(BUILD_DIR_DEV)\\include\\%D /y >nul");
 	TF.Close();

 	MF.WriteBlankLines(2);

Modified: php/php-src/trunk/win32/build/Makefile
===================================================================
--- php/php-src/trunk/win32/build/Makefile	2010-12-14 01:48:31 UTC (rev 306355)
+++ php/php-src/trunk/win32/build/Makefile	2010-12-14 02:55:26 UTC (rev 306356)
@@ -25,10 +25,12 @@
 PHP_BUILD=$(PHP_BUILD)

 MCFILE=$(BUILD_DIR)\wsyslog.rc
+BUILD_DIR_DEV_NAME=php-$(PHP_VERSION_STRING)-devel-$(PHP_COMPILER_SHORT)-$(PHP_ARCHITECTURE)
+BUILD_DIR_DEV=$(BUILD_DIR)\$(BUILD_DIR_DEV_NAME)

 all: generated_files $(EXT_TARGETS) $(PECL_TARGETS) $(SAPI_TARGETS)

-build_dirs: $(BUILD_DIR) $(BUILD_DIRS_SUB)
+build_dirs: $(BUILD_DIR) $(BUILD_DIRS_SUB) $(BUILD_DIR_DEV)

 !if $(RE2C) == ""
 generated_files: build_dirs Zend\zend_ini_parser.c \
@@ -85,10 +87,11 @@

 $(BUILD_DIR)\$(PHPLIB): $(BUILD_DIR)\$(PHPDLL)

-$(BUILD_DIR) $(BUILD_DIRS_SUB):
+$(BUILD_DIR) $(BUILD_DIRS_SUB) $(BUILD_DIR_DEV):
 	@echo Recreating build dirs
 	@if not exist $(BUILD_DIR) mkdir $(BUILD_DIR)
 	@for %D in ($(BUILD_DIRS_SUB)) do @if not exist %D @mkdir %D > NUL
+	@if not exist $(BUILD_DIR_DEV) @mkdir $(BUILD_DIR_DEV) > NUL

 clean-sapi:
 	@echo Cleaning SAPI
@@ -140,10 +143,13 @@
 	cd ..\..
 	cd $(BUILD_DIR)
 	-$(ZIP) -9 -q php-debug-pack-$(PHP_VERSION_STRING)$(PHP_ZTS_ARCHIVE_POSTFIX)-Win32-$(PHP_COMPILER_SHORT)-$(PHP_ARCHITECTURE).zip *.pdb
+	cd
+	cd
+	-$(ZIP) -9 -q -r php-devel-pack-$(PHP_VERSION_STRING)$(PHP_ZTS_ARCHIVE_POSTFIX)-Win32-$(PHP_COMPILER_SHORT)-$(PHP_ARCHITECTURE).zip $(BUILD_DIR_DEV_NAME)
 	cd ..\..

 dist: all build-dist
-snap: build-snap build-dist
+snap: build-devel build-lib build-snap build-dist

 $(BUILD_DIR)\deplister.exe:	win32\build\deplister.c
 	$(PHP_CL) /Fo$(BUILD_DIR)\ /Fd$(BUILD_DIR)\ /Fp$(BUILD_DIR)\ /FR$(BUILD_DIR) /Fe$(BUILD_DIR)\deplister.exe win32\build\deplister.c imagehlp.lib
@@ -152,24 +158,27 @@
 	$(BUILD_DIR)\php.exe ..\php-installer\build-installer.php "$(BUILD_DIR)" "$(PHPDLL)" "$(SAPI_TARGETS)" "$(EXT_TARGETS)" "$(PECL_TARGETS)"

 # need to redirect, since INSTALL is a file in the root...
-install: really-install install-devel install-lib
+install: really-install install-sdk

-install-lib:
-	@if not exist $(PHP_PREFIX)\lib mkdir $(PHP_PREFIX)\lib >nul
-	@copy $(BUILD_DIR)\$(PHPLIB) $(PHP_PREFIX)\lib /y >nul
+build-lib:
+	@if not exist $(BUILD_DIR_DEV)\lib mkdir $(BUILD_DIR_DEV)\lib >nul
+	@copy $(BUILD_DIR)\$(PHPLIB) $(BUILD_DIR_DEV)\lib /y >nul

-install-devel: install-headers
-	@if not exist $(PHP_PREFIX)\script mkdir $(PHP_PREFIX)\script >nul
-	@if not exist $(PHP_PREFIX)\build mkdir $(PHP_PREFIX)\build >nul
-	@copy win32\build\confutils.js $(PHP_PREFIX)\script\ /y >nul
-	@copy win32\build\configure.tail $(PHP_PREFIX)\script\ /y >nul
-	@copy win32\build\config.w32.phpize.in $(PHP_PREFIX)\script\ /y >nul
-	@copy win32\build\Makefile.phpize $(PHP_PREFIX)\script\ /y >nul
-	@copy win32\build\phpize.bat $(PHP_PREFIX)\ /y >nul
-	@copy win32\build\template.rc $(PHP_PREFIX)\build\ /y >nul
-	@copy $(BUILD_DIR)\devel\config.phpize.js $(PHP_PREFIX)\script\ /y >nul
-	@copy $(BUILD_DIR)\devel\phpize.js $(PHP_PREFIX)\script\ /y >nul
+build-devel: build-headers build-lib
+	@if not exist $(BUILD_DIR_DEV)\script mkdir $(BUILD_DIR_DEV)\script >nul
+	@if not exist $(BUILD_DIR_DEV)\build mkdir $(BUILD_DIR_DEV)\build >nul
+	@copy win32\build\confutils.js $(BUILD_DIR_DEV)\script\ /y >nul
+	@copy win32\build\configure.tail $(BUILD_DIR_DEV)\script\ /y >nul
+	@copy win32\build\config.w32.phpize.in $(BUILD_DIR_DEV)\script\ /y >nul
+	@copy win32\build\Makefile.phpize $(BUILD_DIR_DEV)\script\ /y >nul
+	@copy win32\build\phpize.bat $(BUILD_DIR_DEV)\ /y >nul
+	@copy win32\build\template.rc $(BUILD_DIR_DEV)\build\ /y >nul
+	@copy $(BUILD_DIR)\devel\config.phpize.js $(BUILD_DIR_DEV)\script\ /y >nul
+	@copy $(BUILD_DIR)\devel\phpize.js $(BUILD_DIR_DEV)\script\ /y >nul

+install-sdk: build-devel
+	@xcopy /Q /Y /E /I $(BUILD_DIR_DEV)\* $(PHP_PREFIX)\SDK
+
 really-install:
 	@if not exist $(PHP_PREFIX) mkdir $(PHP_PREFIX)
 	@echo Installing files under $(PHP_PREFIX)

Modified: php/php-src/trunk/win32/build/confutils.js
===================================================================
--- php/php-src/trunk/win32/build/confutils.js	2010-12-14 01:48:31 UTC (rev 306355)
+++ php/php-src/trunk/win32/build/confutils.js	2010-12-14 02:55:26 UTC (rev 306356)
@@ -1720,17 +1720,17 @@

 	MF.Write(TF.ReadAll());

-	MF.WriteLine("install-headers:");
-	MF.WriteLine("	@if not exist $(PHP_PREFIX)\\include mkdir $(PHP_PREFIX)\\include >nul");
-	MF.WriteLine("	@for %D in ($(INSTALL_HEADERS_DIR)) do @if not exist $(PHP_PREFIX)\\include\\%D mkdir $(PHP_PREFIX)\\include\\%D >nul");
+	MF.WriteLine("build-headers:");
+	MF.WriteLine("	@if not exist $(BUILD_DIR_DEV)\\include mkdir $(BUILD_DIR_DEV)\\include >nul");
+	MF.WriteLine("	@for %D in ($(INSTALL_HEADERS_DIR)) do @if not exist $(BUILD_DIR_DEV)\\include\\%D mkdir $(BUILD_DIR_DEV)\\include\\%D >nul");
 	for (i in headers_install) {
 		if (headers_install[i][2] != "") {
-				MF.WriteLine("	@if not exist $(PHP_PREFIX)\\include\\" + headers_install[i][2] + " mkdir $(PHP_PREFIX)\\include\\" +
+				MF.WriteLine("	@if not exist $(BUILD_DIR_DEV)\\include\\" + headers_install[i][2] + " mkdir $(BUILD_DIR_DEV)\\include\\" +
 												headers_install[i][2] + ">nul");
-				MF.WriteLine("	@copy " + headers_install[i][0] + " " + "$(PHP_PREFIX)\\include\\" + headers_install[i][2] + " /y >nul");
+				MF.WriteLine("	@copy " + headers_install[i][0] + " " + "$(BUILD_DIR_DEV)\\include\\" + headers_install[i][2] + " /y >nul");
 		}
 	}
-	MF.WriteLine("	@for %D in ($(INSTALL_HEADERS_DIR)) do @copy %D*.h $(PHP_PREFIX)\\include\\%D /y >nul");
+	MF.WriteLine("	@for %D in ($(INSTALL_HEADERS_DIR)) do @copy %D*.h $(BUILD_DIR_DEV)\\include\\%D /y >nul");
 	TF.Close();

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

Reply via email to