forked from microsoft/AirSim
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build_all_ue_projects.bat
68 lines (55 loc) · 1.58 KB
/
build_all_ue_projects.bat
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
@echo off
REM //---------- set up variable ----------
setlocal
set ROOT_DIR=%~dp0
REM should rebuild?
set RebuildAirSim=%1
REM root folder containing all Unreal projects you want to build
set UnrealProjsPath=%2
REM Output folder where the builds would be stored
set OutputPath=%3
REM folder containing AirSim repo
set AirSimPath=%4
REM set defaults if ars are not supplied
if "%UnrealProjsPath%"=="" set "UnrealProjsPath=D:\vso\msresearch\Theseus"
if "%AirSimPath%"=="" set "AirSimPath=C:\GitHubSrc\AirSim"
if "%OutputPath%"=="" set "OutputPath=%ROOT_DIR%build"
if "%RebuildAirSim%"=="" set "RebuildAirSim=true"
REM re-build airsim
if "%RebuildAirSim%"=="true" (
cd /D "%AirSimPath%"
CALL clean
CALL build
if ERRORLEVEL 1 goto :failed
cd /D "%ROOT_DIR%"
)
IF NOT EXIST "%OutputPath%" mkdir "%OutputPath%"
call:doOneProject "CityEnviron"
call:doOneProject "ZhangJiaJie"
call:doOneProject "AirSimEnvNH"
call:doOneProject "LandscapeMountains"
call:doOneProject "Africa_001" "Africa"
call:doOneProject "SimpleMaze"
call:doOneProject "Coastline"
call:doOneProject "Warehouse"
call:doOneProject "Forest"
goto :done
:doOneProject
if "%~2"=="" (
cd /D "%UnrealProjsPath%\%~1"
) else (
cd /D "%UnrealProjsPath%\%~2"
)
if ERRORLEVEL 1 goto :failed
robocopy "%AirSimPath%\Unreal\Environments\Blocks" . update_from_git.bat /njh /njs /ndl /np
CALL update_from_git.bat "%AirSimPath%"
if ERRORLEVEL 1 goto :failed
CALL package.bat "%OutputPath%"
if ERRORLEVEL 1 goto :failed
goto :done
:failed
echo "Error occured while building all UE projects"
exit /b 1
:done
cd "%ROOT_DIR%"
if "%1"=="" pause