Take a look at the attached script...

At 03:58 PM 5/17/2002, Wez Furlong wrote:
>Hey,
>
>I'm in the process of getting a more permanent win32 build environment sorted
>out, and one of the things I'd like to do is avoid the VS IDE as much as
>possible, and automate builds so that I can test changes that I make under
>unix. (Perhaps even by rshing to my win32 box).
>
>I know it's possible to build projects from the command line using something
>like "msdev xxx.dsw", but so far I've not succeeded (and have little patience
>with win32 and the command line, because it is generally quite limited).
>
>Could someone give me some pointers?  (Edin or Sebastian I think?)
>
>--Wez.
>
>--
>Wez Furlong
>The Brain Room Ltd.
>
>
>--
>PHP Development Mailing List <http://www.php.net/>
>To unsubscribe, visit: http://www.php.net/unsub.php
@echo off
rem Usage:  build_php <php_version> [configuration] [build/rebuild]
rem 
rem php_version - Can be:
rem 1) A real PHP version, e.g. 4.0.3pl1, in which case
rem    php-4.0.3pl1 will be used as the PHP source tree
rem 2) "cvs", in which case the 'php4' directory will be used
rem 3) "cvsup", which is like "cvs", except the CVS repository
rem    will be updated first
rem
rem Author:  Zeev Suraski <[EMAIL PROTECTED]>

rem Defaults
set configuration=Release_TS
set build_type=/rebuild


if "%1" == "" goto no_php_version

:determine_configuration
rem Determine the configuration
if not "%2" == "" set configuration=%2

:determine_rebuild
rem Determine if we need to rebuild or not
if "%3" == "" goto determine_dir_suffix
if "%3" == "build" set build_type=
if "%3" == "rebuild" set build_type=/rebuild

:determine_dir_suffix
rem Determine directory suffix
set php_suffix=-%1

rem Handle CVS
if "%php_suffix%" == "-cvs" goto cvs
if "%php_suffix%" == "-cvsup" goto cvs
goto common

:cvs
set php_suffix=4

if not "%1" == "cvsup" goto common

cd php%php_suffix%
echo Updating php4 CVS...
cvs update -d
cd Zend
echo Updating Zend CVS...
cvs update -d
cd ..\TSRM
echo Updating TSRM CVS...
cvs update -d
cd ..
cd ..
goto common

:common
call vcvars32.bat


echo Building PHP %1 - Win32 %configuration%
cd php%php_suffix%\win32
msdev php4ts.dsw /make "php4dllts - Win32 %configuration%" %build_type%
msdev php4ts.dsw /make "php4ts - Win32 %configuration%"
msdev php4ts.dsw /make "php4isapi - Win32 %configuration%"
cd ..
cd ..

goto end

:no_php_version
echo Usage:  build_php [php_version] [configuration] [build/rebuild]
echo (default configuration: %configuration% %build_type%)
goto end

:end

-- 
PHP Development Mailing List <http://www.php.net/>
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to