mirror of
https://github.com/reactos/RosBE.git
synced 2024-11-23 11:29:44 +00:00
Circumvent another Batch silliness with a if block and some code not be parsed in a row problem... thx to Colin for the suggestion to fix it this way
svn path=/trunk/tools/RosBE/; revision=990
This commit is contained in:
parent
e5d1a6fd99
commit
84b2d074e4
24
RosBE-Windows/Root/Build-Multi.cmd
Normal file
24
RosBE-Windows/Root/Build-Multi.cmd
Normal file
@ -0,0 +1,24 @@
|
||||
::
|
||||
:: PROJECT: RosBE - ReactOS Build Environment for Windows
|
||||
:: LICENSE: GNU General Public License v2. (see LICENSE.txt)
|
||||
:: FILE: Root/Build-Multi.cmd
|
||||
:: PURPOSE: Perform a multiprocessor build
|
||||
:: COPYRIGHT: Copyright 2009 Daniel Reimer <reimer.daniel@freenet.de>
|
||||
:: Colin Finck <colin@reactos.org>
|
||||
:: Peter Ward <dralnix@gmail.com>
|
||||
::
|
||||
|
||||
@echo off
|
||||
if not defined _ROSBE_DEBUG set _ROSBE_DEBUG=0
|
||||
if %_ROSBE_DEBUG% == 1 (
|
||||
@echo on
|
||||
)
|
||||
|
||||
setlocal enabledelayedexpansion
|
||||
|
||||
:: Set the options for a multiprocessor build
|
||||
set MAKE_JOBS=%_ROSBE_MAKEX_JOBS%
|
||||
set TITLE_COMMAND=makex %*
|
||||
|
||||
call "%_ROSBE_BASEDIR%\Build-Shared.cmd" %*
|
||||
endlocal
|
65
RosBE-Windows/Root/Build-Shared.cmd
Normal file
65
RosBE-Windows/Root/Build-Shared.cmd
Normal file
@ -0,0 +1,65 @@
|
||||
::
|
||||
:: PROJECT: RosBE - ReactOS Build Environment for Windows
|
||||
:: LICENSE: GNU General Public License v2. (see LICENSE.txt)
|
||||
:: FILE: Root/Build-Shared.cmd
|
||||
:: PURPOSE: Perform the build of ReactOS.
|
||||
:: COPYRIGHT: Copyright 2009 Daniel Reimer <reimer.daniel@freenet.de>
|
||||
:: Colin Finck <colin@reactos.org>
|
||||
:: Peter Ward <dralnix@gmail.com>
|
||||
::
|
||||
|
||||
@echo off
|
||||
if not defined _ROSBE_DEBUG set _ROSBE_DEBUG=0
|
||||
if %_ROSBE_DEBUG% == 1 (
|
||||
@echo on
|
||||
)
|
||||
|
||||
:: Check if config.template.rbuild is newer than config.rbuild, if it is then
|
||||
:: abort the build and inform the user.
|
||||
if exist .\config.rbuild (
|
||||
"%_ROSBE_BASEDIR%\Tools\chknewer.exe" .\config.template.rbuild .\config.rbuild
|
||||
if !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 :EOC
|
||||
)
|
||||
)
|
||||
|
||||
call "%_ROSBE_BASEDIR%\TranslateOptions.cmd"
|
||||
|
||||
if "%_ROSBE_USECCACHE%" == "1" (
|
||||
set _ROSBE_CCACHE=ccache
|
||||
) else (
|
||||
set _ROSBE_CCACHE=
|
||||
)
|
||||
|
||||
set HOST_CC=%_ROSBE_CCACHE%gcc
|
||||
set HOST_CPP=%_ROSBE_CCACHE%g++
|
||||
set TARGET_CC=%_ROSBE_CCACHE%%ROS_PREFIX%gcc
|
||||
set TARGET_CPP=%_ROSBE_CCACHE%%ROS_PREFIX%g++
|
||||
|
||||
:: Get the current date and time for use in in our build log's file name.
|
||||
call "%_ROSBE_BASEDIR%\TimeDate.cmd"
|
||||
|
||||
title '%TITLE_COMMAND%' build started: %TIMERAW% (%ROS_ARCH%)
|
||||
|
||||
:: Do the actual building
|
||||
if %_ROSBE_SHOWTIME% == 1 (
|
||||
set BUILDTIME_COMMAND="%_ROSBE_BASEDIR%\Tools\buildtime.exe"
|
||||
) else (
|
||||
set BUILDTIME_COMMAND=
|
||||
)
|
||||
|
||||
if %_ROSBE_WRITELOG% == 1 (
|
||||
%BUILDTIME_COMMAND% "%_ROSBE_MINGWMAKE%" -j %MAKE_JOBS% %* 2>&1 | "%_ROSBE_BASEDIR%\Tools\tee.exe" "%_ROSBE_LOGDIR%\BuildLog-%_ROSBE_TARGET_GCCVERSION%-%datename%-%timename%.txt"
|
||||
) else (
|
||||
%BUILDTIME_COMMAND% "%_ROSBE_MINGWMAKE%" -j %MAKE_JOBS% %*
|
||||
)
|
||||
|
||||
:EOC
|
||||
:: Highlight the fact that building has ended.
|
||||
"%_ROSBE_BASEDIR%\Tools\flash.exe"
|
||||
title ReactOS Build Environment %_ROSBE_VERSION%
|
@ -2,7 +2,7 @@
|
||||
:: PROJECT: RosBE - ReactOS Build Environment for Windows
|
||||
:: LICENSE: GNU General Public License v2. (see LICENSE.txt)
|
||||
:: FILE: Root/Build.cmd
|
||||
:: PURPOSE: Perform the build of ReactOS.
|
||||
:: PURPOSE: Perform a uniprocessor build
|
||||
:: COPYRIGHT: Copyright 2009 Daniel Reimer <reimer.daniel@freenet.de>
|
||||
:: Colin Finck <colin@reactos.org>
|
||||
:: Peter Ward <dralnix@gmail.com>
|
||||
@ -16,63 +16,9 @@ if %_ROSBE_DEBUG% == 1 (
|
||||
|
||||
setlocal enabledelayedexpansion
|
||||
|
||||
:: Check if config.template.rbuild is newer than config.rbuild, if it is then
|
||||
:: abort the build and inform the user.
|
||||
if exist .\config.rbuild (
|
||||
"%_ROSBE_BASEDIR%\Tools\chknewer.exe" .\config.template.rbuild .\config.rbuild
|
||||
if !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 :EOC
|
||||
)
|
||||
)
|
||||
:: Set the options for a uniprocessor build
|
||||
set MAKE_JOBS=1
|
||||
set TITLE_COMMAND=make %*
|
||||
|
||||
call "%_ROSBE_BASEDIR%\TranslateOptions.cmd"
|
||||
|
||||
if "%_ROSBE_USECCACHE%" == "1" (
|
||||
set _ROSBE_CCACHE=ccache
|
||||
) else (
|
||||
set _ROSBE_CCACHE=
|
||||
)
|
||||
|
||||
set HOST_CC=%_ROSBE_CCACHE%gcc
|
||||
set HOST_CPP=%_ROSBE_CCACHE%g++
|
||||
set TARGET_CC=%_ROSBE_CCACHE%%ROS_PREFIX%gcc
|
||||
set TARGET_CPP=%_ROSBE_CCACHE%%ROS_PREFIX%g++
|
||||
|
||||
:: Get the current date and time for use in in our build log's file name.
|
||||
call "%_ROSBE_BASEDIR%\TimeDate.cmd"
|
||||
|
||||
:: Check whether we were called as "makex" or "make"
|
||||
if "%1" == "multi" (
|
||||
shift
|
||||
set MAKE_JOBS=%_ROSBE_MAKEX_JOBS%
|
||||
set TITLE_COMMAND=makex %2%3%4%5%6%7%8%9
|
||||
) else (
|
||||
set MAKE_JOBS=1
|
||||
set TITLE_COMMAND=make %*
|
||||
)
|
||||
|
||||
title '%TITLE_COMMAND%' build started: %TIMERAW% (%ROS_ARCH%)
|
||||
|
||||
:: Do the actual building
|
||||
if %_ROSBE_SHOWTIME% == 1 (
|
||||
set BUILDTIME_COMMAND="%_ROSBE_BASEDIR%\Tools\buildtime.exe"
|
||||
) else (
|
||||
set BUILDTIME_COMMAND=
|
||||
)
|
||||
|
||||
if %_ROSBE_WRITELOG% == 1 (
|
||||
%BUILDTIME_COMMAND% "%_ROSBE_MINGWMAKE%" -j %MAKE_JOBS% %1 %2 %3 %4 %5 %6 %7 %8 %9 2>&1 | "%_ROSBE_BASEDIR%\Tools\tee.exe" "%_ROSBE_LOGDIR%\BuildLog-%_ROSBE_TARGET_GCCVERSION%-%datename%-%timename%.txt"
|
||||
) else (
|
||||
%BUILDTIME_COMMAND% "%_ROSBE_MINGWMAKE%" -j %MAKE_JOBS% %1 %2 %3 %4 %5 %6 %7 %8 %9
|
||||
)
|
||||
|
||||
:EOC
|
||||
:: Highlight the fact that building has ended.
|
||||
"%_ROSBE_BASEDIR%\Tools\flash.exe"
|
||||
title ReactOS Build Environment %_ROSBE_VERSION%
|
||||
call "%_ROSBE_BASEDIR%\Build-Shared.cmd" %*
|
||||
endlocal
|
||||
|
@ -7,7 +7,7 @@ CONFIG = "%_ROSBE_BASEDIR%\Config.cmd" $*
|
||||
ENV = set
|
||||
HELP = "%_ROSBE_BASEDIR%\Help.cmd" $*
|
||||
MAKE = "%_ROSBE_BASEDIR%\Build.cmd" $*
|
||||
MAKEX = "%_ROSBE_BASEDIR%\Build.cmd" multi $*
|
||||
MAKEX = "%_ROSBE_BASEDIR%\Build-Multi.cmd" $*
|
||||
RADDR2LINE = "%_ROSBE_BASEDIR%\reladdr2line.cmd" $*
|
||||
RENV = for /f "usebackq tokens=*" %i in (`set _ROSBE_`) do @echo %i
|
||||
SCUT = "%_ROSBE_BASEDIR%\scut.cmd" $*
|
||||
|
@ -131,6 +131,8 @@ Section -BaseFiles SEC01
|
||||
WriteRegStr HKLM "Software\Microsoft\PowerShell\1\ShellIds\Microsoft.PowerShell" "ExecutionPolicy" "RemoteSigned"
|
||||
${else}
|
||||
File /r Root\Build.cmd
|
||||
File /r Root\Build-Multi.cmd
|
||||
File /r Root\Build-Shared.cmd
|
||||
File /r Root\charch.cmd
|
||||
File /r Root\chdefgcc.cmd
|
||||
File /r Root\Clean.cmd
|
||||
@ -297,6 +299,8 @@ SetShellVarContext current
|
||||
SetOutPath "$INSTDIR"
|
||||
SetOverwrite try
|
||||
File /r Root\Build.cmd
|
||||
File /r Root\Build-Multi.cmd
|
||||
File /r Root\Build-Shared.cmd
|
||||
File /r Root\chdefgcc.cmd
|
||||
File /r Root\Clean.cmd
|
||||
File /r Root\Help.cmd
|
||||
@ -447,6 +451,8 @@ Section Uninstall
|
||||
RMDir /r /REBOOTOK "$INSTDIR\Tools"
|
||||
RMDir /r /REBOOTOK "$SMPROGRAMS\$ICONS_GROUP"
|
||||
Delete /REBOOTOK "$INSTDIR\Build.cmd"
|
||||
Delete /REBOOTOK "$INSTDIR\Build-Multi.cmd"
|
||||
Delete /REBOOTOK "$INSTDIR\Build-Shared.cmd"
|
||||
Delete /REBOOTOK "$INSTDIR\Build.ps1"
|
||||
Delete /REBOOTOK "$INSTDIR\chdefdir.cmd"
|
||||
Delete /REBOOTOK "$INSTDIR\chdefdir.ps1"
|
||||
|
Loading…
Reference in New Issue
Block a user