@@ -82,26 +82,27 @@ if "%SKIPBUILD%" EQU "1" goto skipdoc
8282if " %SKIPDOC% " EQU " 1" goto skipdoc
8383
8484call " %D% ..\..\doc\make.bat" htmlhelp
85- if errorlevel 1 goto : eof
85+ if errorlevel 1 exit /B %ERRORLEVEL%
8686:skipdoc
8787
8888if defined BUILDX86 (
8989 call :build x86
90- if errorlevel 1 exit /B
90+ if errorlevel 1 exit /B %ERRORLEVEL%
9191)
9292
9393if defined BUILDX64 (
9494 call :build x64 " %PGO% "
95- if errorlevel 1 exit /B
95+ if errorlevel 1 exit /B %ERRORLEVEL%
9696)
9797
9898if defined BUILDARM64 (
9999 call :build ARM64
100- if errorlevel 1 exit /B
100+ if errorlevel 1 exit /B %ERRORLEVEL%
101101)
102102
103103if defined TESTTARGETDIR (
104104 call " %D% testrelease.bat" -t " %TESTTARGETDIR% "
105+ if errorlevel 1 exit /B %ERRORLEVEL%
105106)
106107
107108exit /B 0
@@ -136,19 +137,19 @@ if "%1" EQU "x86" (
136137if exist " %BUILD% en-us" (
137138 echo Deleting %BUILD% en-us
138139 rmdir /q/s " %BUILD% en-us"
139- if errorlevel 1 exit /B
140+ if errorlevel 1 exit /B %ERRORLEVEL%
140141)
141142
142143if exist " %D% obj\Debug_%OBJDIR_PLAT% " (
143144 echo Deleting " %D% obj\Debug_%OBJDIR_PLAT% "
144145 rmdir /q/s " %D% obj\Debug_%OBJDIR_PLAT% "
145- if errorlevel 1 exit /B
146+ if errorlevel 1 exit /B %ERRORLEVEL%
146147)
147148
148149if exist " %D% obj\Release_%OBJDIR_PLAT% " (
149150 echo Deleting " %D% obj\Release_%OBJDIR_PLAT% "
150151 rmdir /q/s " %D% obj\Release_%OBJDIR_PLAT% "
151- if errorlevel 1 exit /B
152+ if errorlevel 1 exit /B %ERRORLEVEL%
152153)
153154
154155if not " %CERTNAME% " EQU " " (
@@ -164,37 +165,37 @@ if not "%PGO%" EQU "" (
164165if not " %SKIPBUILD% " EQU " 1" (
165166 @ echo call " %PCBUILD% build.bat" -e -p %BUILD_PLAT% -t %TARGET% %PGOOPTS% %CERTOPTS%
166167 @ call " %PCBUILD% build.bat" -e -p %BUILD_PLAT% -t %TARGET% %PGOOPTS% %CERTOPTS%
167- @ if errorlevel 1 exit /B
168+ @ if errorlevel 1 exit /B %ERRORLEVEL%
168169 @ rem build.bat turns echo back on, so we disable it again
169170 @ echo off
170171
171172 @ echo call " %PCBUILD% build.bat" -d -e -p %BUILD_PLAT% -t %TARGET%
172173 @ call " %PCBUILD% build.bat" -d -e -p %BUILD_PLAT% -t %TARGET%
173- @ if errorlevel 1 exit /B
174+ @ if errorlevel 1 exit /B %ERRORLEVEL%
174175 @ rem build.bat turns echo back on, so we disable it again
175176 @ echo off
176177)
177178
178179if " %OUTDIR_PLAT% " EQU " win32" (
179180 %MSBUILD% " %D% launcher\launcher.wixproj" /p:Platform=x86 %CERTOPTS% /p:ReleaseUri=%RELEASE_URI%
180- if errorlevel 1 exit /B
181+ if errorlevel 1 exit /B %ERRORLEVEL%
181182) else if not exist " %Py_OutDir% win32\en-us\launcher.msi" (
182183 %MSBUILD% " %D% launcher\launcher.wixproj" /p:Platform=x86 %CERTOPTS% /p:ReleaseUri=%RELEASE_URI%
183- if errorlevel 1 exit /B
184+ if errorlevel 1 exit /B %ERRORLEVEL%
184185)
185186
186187set BUILDOPTS = /p:Platform=%1 /p:BuildForRelease=true /p:DownloadUrl=%DOWNLOAD_URL% /p:DownloadUrlBase=%DOWNLOAD_URL_BASE% /p:ReleaseUri=%RELEASE_URI%
187188if defined BUILDMSI (
188189 %MSBUILD% " %D% bundle\releaselocal.wixproj" /t:Rebuild %BUILDOPTS% %CERTOPTS% /p:RebuildAll=true
189- if errorlevel 1 exit /B
190+ if errorlevel 1 exit /B %ERRORLEVEL%
190191)
191192
192193if defined BUILDZIP (
193194 if " %BUILD_PLAT% " EQU " ARM64" (
194195 echo Skipping embeddable ZIP generation for ARM64 platform
195196 ) else (
196197 %MSBUILD% " %D% make_zip.proj" /t:Build %BUILDOPTS% %CERTOPTS% /p:OutputPath=" %BUILD% en-us"
197- if errorlevel 1 exit /B
198+ if errorlevel 1 exit /B %ERRORLEVEL%
198199 )
199200)
200201
@@ -203,7 +204,7 @@ if defined BUILDNUGET (
203204 echo Skipping Nuget package generation for ARM64 platform
204205 ) else (
205206 %MSBUILD% " %D% ..\nuget\make_pkg.proj" /t:Build /p:Configuration=Release /p:Platform=%1 /p:OutputPath=" %BUILD% en-us"
206- if errorlevel 1 exit /B
207+ if errorlevel 1 exit /B %ERRORLEVEL%
207208 )
208209)
209210
0 commit comments