diff --git a/vcbuild.bat b/vcbuild.bat index 05f2a1c268772c..4248bc4aa8ee5a 100644 --- a/vcbuild.bat +++ b/vcbuild.bat @@ -82,7 +82,8 @@ if /i "%1"=="ignore-flaky" set test_args=%test_args% --flaky-tests=dontcare&got if /i "%1"=="enable-vtune" set enable_vtune_arg=1&goto arg-ok if /i "%1"=="dll" set dll=1&goto arg-ok -echo Warning: ignoring invalid command line option `%1`. +echo Error: invalid command line option `%1`. +exit /b 1 :arg-ok :arg-ok @@ -128,6 +129,8 @@ call :getnodeversion || exit /b 1 if "%target%"=="Clean" rmdir /Q /S "%~dp0%config%\node-v%FULLVERSION%-win-%target_arch%" > nul 2> nul +if defined noprojgen if defined nobuild if defined nosign if not defined msi goto licensertf + @rem Set environment for msbuild if defined target_env if "%target_env%" NEQ "vc2015" goto vc-set-2013 @@ -340,12 +343,16 @@ for /d %%F in (test\addons\??_*) do ( ) :: generate "%node_exe%" tools\doc\addon-verify.js +if %errorlevel% neq 0 exit /b %errorlevel% :: building addons +SetLocal EnableDelayedExpansion for /d %%F in (test\addons\*) do ( "%node_exe%" deps\npm\node_modules\node-gyp\bin\node-gyp rebuild ^ --directory="%%F" ^ --nodedir="%cd%" + if !errorlevel! neq 0 exit /b !errorlevel! ) +EndLocal goto run-tests :run-tests