Skip to content

Commit

Permalink
added check for old versions for existing users
Browse files Browse the repository at this point in the history
  • Loading branch information
sytelus committed Apr 28, 2018
1 parent d36e897 commit 58a20b0
Show file tree
Hide file tree
Showing 3 changed files with 37 additions and 2 deletions.
20 changes: 18 additions & 2 deletions build.cmd
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,20 @@ set ROOT_DIR=%~dp0
REM // Check command line arguments
set "noFullPolyCar="

REM //check VS version
if "%VisualStudioVersion%"=="" (
echo(
echo oh oh... You need to run this command from x64 Native Tools Command Prompt for VS 2017.
goto :buildfailed_nomsg
)
if "%VisualStudioVersion%"=="14.0" (
echo(
echo Hello there! We just upgraded AirSim to Unreal Engine 4.18 and Visual Studio 2017.
echo Here are few easy steps for upgrade so everything is new and shiny:
echo https://github.com/Microsoft/AirSim/blob/master/docs/unreal_upgrade.md
goto :buildfailed_nomsg
)

if "%1"=="" goto noargs
if "%1"=="--no-full-poly-car" set "noFullPolyCar=y"

Expand All @@ -19,7 +33,7 @@ if ERRORLEVEL 1 (
CALL check_cmake.bat
if ERRORLEVEL 1 (
echo(
echo ERROR: cmake was not installed correctly.
echo ERROR: cmake was not installed correctly, we tried.
goto :buildfailed
)
)
Expand Down Expand Up @@ -141,9 +155,11 @@ REM //---------- done building ----------
exit /b 0

:buildfailed
chdir /d %ROOT_DIR%
echo(
echo #### Build failed - see messages above. 1>&2

:buildfailed_nomsg
chdir /d %ROOT_DIR%
exit /b 1


Expand Down
12 changes: 12 additions & 0 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,18 @@ pushd "$SCRIPT_DIR" >/dev/null
set -e
# set -x

#check for correct verion of llvm
if [[ ! -d "llvm-source-50" ]]; then
if [[ -d "llvm-source-39" ]]; then
echo "Hello there! We just upgraded AirSim to Unreal Engine 4.18."
echo "Here are few easy steps for upgrade so everything is new and shiny :)"
echo "https://github.com/Microsoft/AirSim/blob/master/docs/unreal_upgrade.md"
exit 1
else
echo "The llvm-souce-50 folder was not found! Mystery indeed.""
fi
fi
# check for libc++
if [[ !(-d "./llvm-build/output/lib") ]]; then
echo "ERROR: clang++ and libc++ is necessary to compile AirSim and run it in Unreal engine"
Expand Down
7 changes: 7 additions & 0 deletions setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,13 @@
set -x
set -e

if [[ -d "llvm-source-39" ]]; then
echo "Hello there! We just upgraded AirSim to Unreal Engine 4.18."
echo "Here are few easy steps for upgrade so everything is new and shiny :)"
echo "https://github.com/Microsoft/AirSim/blob/master/docs/unreal_upgrade.md"
exit 1
fi

SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
pushd "$SCRIPT_DIR" >/dev/null

Expand Down

0 comments on commit 58a20b0

Please sign in to comment.