Author: gedmurphy
Date: Tue May 29 17:21:50 2007
New Revision: 26936
URL:
http://svn.reactos.org/svn/reactos?rev=26936&view=rev
Log:
- re-organize build scipts to use a common file
- patch by Colin Finck
Added:
trunk/tools/RosBE-Windows/Build-Shared.cmd
Modified:
trunk/tools/RosBE-Windows/Build-Multi.cmd
trunk/tools/RosBE-Windows/Build.cmd
Modified: trunk/tools/RosBE-Windows/Build-Multi.cmd
URL:
http://svn.reactos.org/svn/reactos/trunk/tools/RosBE-Windows/Build-Multi.cm…
==============================================================================
--- trunk/tools/RosBE-Windows/Build-Multi.cmd (original)
+++ trunk/tools/RosBE-Windows/Build-Multi.cmd Tue May 29 17:21:50 2007
@@ -12,12 +12,6 @@
set CPUCOUNT=
::
-:: Get the current date and time for use in
-:: in our build log's file name.
-::
-call "%ROSBEBASEDIR%\TimeDate.cmd"
-
-::
:: Get the number of CPUs in the system so we know how
:: many jobs to execute.
:: To modify the number used alter the options used with cpucount:
@@ -27,26 +21,11 @@
for /f "usebackq" %%i in (`"%ROSBEBASEDIR%\Tools\cpucount.exe" -x1`)
do set CPUCOUNT=%%i
::
-:: Check if config.template.rbuild is newer than config.rbuild,
-:: if it is then abort the build and inform the user.
+:: Set the build command
::
-if exist "%_ROSSOURCEDIR%\config.rbuild" (
- "%ROSBEBASEDIR%\Tools\test.exe"
"%_ROSSOURCEDIR%\config.template.rbuild" -nt
"%_ROSSOURCEDIR%\config.rbuild"
- if not errorlevel 1 (
- echo.
- echo *** config.template.rbuild is newer than config.rbuild ***
- echo *** aborting build. Please check for changes and ***
- echo *** update your config.rbuild. ***
- echo.
- goto :EOF
- )
-)
+set MAKE_COMMAND="%_MINGWMAKE%" -j %CPUCOUNT% %*
::
-:: Now use mingw32-make to build ReactOS, passing along options, if any.
+:: Execute the shared build commands
::
-if "%1" == "" (
- "%ROSBEBASEDIR%\Tools\buildtime.exe" "%_MINGWMAKE%" -j %CPUCOUNT%
2>&1 | "%ROSBEBASEDIR%\Tools\tee.exe"
"%_ROSBELOGDIR%\BuildLog-%_MINGWVERSION%-%DATENAME%-%TIMENAME%.txt"
-) else (
- "%ROSBEBASEDIR%\Tools\buildtime.exe" "%_MINGWMAKE%" -j %CPUCOUNT%
%* 2>&1 | "%ROSBEBASEDIR%\Tools\tee.exe"
"%_ROSBELOGDIR%\BuildLog-%_MINGWVERSION%-%DATENAME%-%TIMENAME%.txt"
-)
+call "%ROSBEBASEDIR%\Build-Shared.cmd"
Added: trunk/tools/RosBE-Windows/Build-Shared.cmd
URL:
http://svn.reactos.org/svn/reactos/trunk/tools/RosBE-Windows/Build-Shared.c…
==============================================================================
--- trunk/tools/RosBE-Windows/Build-Shared.cmd (added)
+++ trunk/tools/RosBE-Windows/Build-Shared.cmd Tue May 29 17:21:50 2007
@@ -1,0 +1,33 @@
+:: Shared actions for "Build.cmd" and "Build-Multi.cmd"
+
+::
+:: Check if config.template.rbuild is newer than config.rbuild,
+:: if it is then abort the build and inform the user.
+::
+if exist "%_ROSSOURCEDIR%\config.rbuild" (
+ "%ROSBEBASEDIR%\Tools\test.exe"
"%_ROSSOURCEDIR%\config.template.rbuild" -nt
"%_ROSSOURCEDIR%\config.rbuild"
+ if not errorlevel 1 (
+ echo.
+ echo *** config.template.rbuild is newer than config.rbuild ***
+ echo *** aborting build. Please check for changes and ***
+ echo *** update your config.rbuild. ***
+ echo.
+ goto :EOF
+ )
+)
+
+::
+:: Get the current date and time for use in
+:: in our build log's file name.
+::
+call %ROSBEBASEDIR%\TimeDate.cmd
+
+::
+:: Execute the Build command
+::
+call "%ROSBEBASEDIR%\Tools\buildtime.exe" %MAKE_COMMAND% 2>&1 |
"%ROSBEBASEDIR%\Tools\tee.exe"
"%_ROSBELOGDIR%\BuildLog-%_MINGWVERSION%-%DATENAME%-%TIMENAME%.txt"
+
+::
+:: highlight the fact that building has ended
+::
+call "%ROSBEBASEDIR%\Tools\flash.exe"
Modified: trunk/tools/RosBE-Windows/Build.cmd
URL:
http://svn.reactos.org/svn/reactos/trunk/tools/RosBE-Windows/Build.cmd?rev=…
==============================================================================
--- trunk/tools/RosBE-Windows/Build.cmd (original)
+++ trunk/tools/RosBE-Windows/Build.cmd Tue May 29 17:21:50 2007
@@ -5,37 +5,11 @@
@echo off
::
-:: Get the current date and time for use in
-:: in our build log's file name.
+:: Set the build command
::
-call "%ROSBEBASEDIR%\TimeDate.cmd"
+set MAKE_COMMAND="%_MINGWMAKE%" %*
::
-:: Check if config.template.rbuild is newer than config.rbuild,
-:: if it is then abort the build and inform the user.
+:: Execute the shared build commands
::
-if exist "%_ROSSOURCEDIR%\config.rbuild" (
- "%ROSBEBASEDIR%\Tools\test.exe"
"%_ROSSOURCEDIR%\config.template.rbuild" -nt
"%_ROSSOURCEDIR%\config.rbuild"
- if not errorlevel 1 (
- echo.
- echo *** config.template.rbuild is newer than config.rbuild ***
- echo *** aborting build. Please check for changes and ***
- echo *** update your config.rbuild. ***
- echo.
- goto :EOF
- )
-)
-
-::
-:: Now use mingw32-make to build ReactOS, passing along options, if any.
-::
-if "%1" == "" (
- "%ROSBEBASEDIR%\Tools\buildtime.exe" "%_MINGWMAKE%" 2>&1 |
"%ROSBEBASEDIR%\Tools\tee.exe"
"%_ROSBELOGDIR%\BuildLog-%_MINGWVERSION%-%DATENAME%-%TIMENAME%.txt"
-) else (
- "%ROSBEBASEDIR%\Tools\buildtime.exe" "%_MINGWMAKE%" %*
2>&1 | "%ROSBEBASEDIR%\Tools\tee.exe"
"%_ROSBELOGDIR%\BuildLog-%_MINGWVERSION%-%DATENAME%-%TIMENAME%.txt"
-)
-
-::
-:: highlight the fact that building has ended
-::
-call "%ROSBEBASEDIR%\Tools\flash.exe"
+call "%ROSBEBASEDIR%\Build-Shared.cmd"