win32: only call 'exit' when building in teamcity
[deb_libcec.git] / support / create-installer.bat
index 2f19005ba7e611eac5bd55f690a0f2490d79293f..d9f6a579d3b3a20d8586250000f3633716b199f3 100644 (file)
@@ -1,5 +1,7 @@
 @echo off
 
+set EXITCODE=1
+
 rem Check for NSIS
 IF EXIST "%ProgramFiles%\NSIS\makensis.exe" (
   set NSIS="%ProgramFiles%\NSIS\makensis.exe"
@@ -134,6 +136,7 @@ IF "%1%"=="" (
   echo. The installer can be found here: ..\build\libCEC-%1%-installer.exe
 )
 
+set EXITCODE=0
 GOTO EXIT
 
 :NOSDK10
@@ -162,3 +165,9 @@ del /s /f /q ..\build\x64
 rmdir ..\build\x64
 cd ..\support
 
+IF "%1%"=="" (
+  echo. exitcode = %EXITCODE%
+) ELSE (
+  exit %EXITCODE%
+)
+