2006-11-19 15:24:09 +01:00
|
|
|
@echo off
|
|
|
|
::==============
|
|
|
|
:: compile.bat solution, output, [projects...]
|
2007-02-26 16:18:41 +01:00
|
|
|
::
|
2016-05-31 19:30:54 +02:00
|
|
|
:: Note: Our projects create object files in temp/$platform/$config
|
2007-02-26 16:18:41 +01:00
|
|
|
:: but we call devenv with $config|$platform (note variable in reverse order
|
2016-03-25 07:45:21 +01:00
|
|
|
:: and odd syntax).
|
2006-11-19 15:24:09 +01:00
|
|
|
|
|
|
|
setlocal
|
|
|
|
set solution=%1
|
2019-04-25 17:20:02 +02:00
|
|
|
set output_path=%~dp2
|
2006-11-19 15:24:09 +01:00
|
|
|
set output=%2
|
2007-02-26 16:18:41 +01:00
|
|
|
set projects=
|
2006-11-19 15:24:09 +01:00
|
|
|
|
2007-02-26 16:18:41 +01:00
|
|
|
@if "%FB_DBG%"=="" (
|
2008-09-02 10:39:33 +02:00
|
|
|
set config=release
|
2006-11-19 15:24:09 +01:00
|
|
|
) else (
|
2008-09-02 10:39:33 +02:00
|
|
|
set config=debug
|
2006-11-19 15:24:09 +01:00
|
|
|
)
|
2008-09-02 10:39:33 +02:00
|
|
|
|
2006-11-19 15:24:09 +01:00
|
|
|
shift
|
|
|
|
shift
|
|
|
|
|
|
|
|
:loop_start
|
|
|
|
|
|
|
|
if "%1" == "" goto loop_end
|
|
|
|
|
2019-04-25 17:20:02 +02:00
|
|
|
set projects=%projects% /target:%1%FB_CLEAN%
|
2006-11-19 15:24:09 +01:00
|
|
|
|
|
|
|
shift
|
|
|
|
goto loop_start
|
|
|
|
|
|
|
|
:loop_end
|
|
|
|
|
2019-10-28 18:50:10 +01:00
|
|
|
if not exist "%output_path%" mkdir "%output_path%"
|
2019-04-25 17:20:02 +02:00
|
|
|
msbuild "%FB_LONG_ROOT_PATH%\%solution%.sln" /maxcpucount /p:Configuration=%config% /p:Platform=%FB_TARGET_PLATFORM% %projects% /fileLoggerParameters:LogFile=%output%
|
2006-11-19 15:24:09 +01:00
|
|
|
|
|
|
|
endlocal
|
|
|
|
|
|
|
|
goto :EOF
|