[Tizen] Add crossgen and coreconsole to coreclr package
[platform/upstream/coreclr.git] / run.cmd
1 @if not defined _echo @echo off
2 setlocal
3
4 set "__ProjectDir=%~dp0"
5
6 call "%__ProjectDir%"\setup_vs_tools.cmd
7
8 REM setup_vs_tools.cmd will correctly echo error message.
9 if NOT '%ERRORLEVEL%' == '0' exit /b 1
10
11 :: Clear the 'Platform' env variable for this session, as it's a per-project setting within the build, and
12 :: misleading value (such as 'MCD' in HP PCs) may lead to build breakage (issue: #69).
13 set Platform=
14 set __ProjectDir=
15
16 :: Restore the Tools directory
17 call %~dp0init-tools.cmd
18 if NOT [%ERRORLEVEL%]==[0] (
19   exit /b 1
20 )
21
22 set _toolRuntime=%~dp0Tools
23 set _dotnet=%_toolRuntime%\dotnetcli\dotnet.exe
24 set _json=%~dp0config.json
25
26 :: run.exe depends on running in the root directory, notably because the config.json specifies
27 :: a relative path to the binclash logger
28
29 pushd %~dp0
30 echo Running: %_dotnet% %_toolRuntime%\run.exe %~dp0config.json %*
31 call %_dotnet% %_toolRuntime%\run.exe "%_json%" %*
32 popd
33 if NOT [%ERRORLEVEL%]==[0] (
34   exit /b 1
35 )
36
37 exit /b 0