diff --git a/paddle/scripts/paddle_build.bat b/paddle/scripts/paddle_build.bat index 2730862205575595cbb325681dec2aba432ca108..c9ac26e1ea9116b3f08335bb6050b20f6905ecd8 100644 --- a/paddle/scripts/paddle_build.bat +++ b/paddle/scripts/paddle_build.bat @@ -114,18 +114,17 @@ if "%WITH_PYTHON%" == "ON" ( ) rem -------Caching strategy 1: keep build directory for incremental compilation----------- +if "%WITH_CACHE%"=="OFF" ( + rmdir %BUILD_DIR% /s/q + goto :mkbuild +) + rmdir %BUILD_DIR%\python /s/q -rmdir %BUILD_DIR%\paddle\third_party\externalError /s/q rmdir %BUILD_DIR%\paddle_install_dir /s/q rmdir %BUILD_DIR%\paddle_inference_install_dir /s/q rmdir %BUILD_DIR%\paddle_inference_c_install_dir /s/q del %BUILD_DIR%\CMakeCache.txt -if "%WITH_CACHE%"=="OFF" ( - rmdir %BUILD_DIR% /s/q - goto :mkbuild -) - : set /p error_code=< %cache_dir%\error_code.txt if %error_code% NEQ 0 ( rmdir %BUILD_DIR% /s/q @@ -179,7 +178,6 @@ if not defined SCCACHE_ROOT set SCCACHE_ROOT=D:\sccache set PATH=%SCCACHE_ROOT%;%PATH% if "%WITH_SCCACHE%"=="ON" ( cmd /C sccache -V || call :install_sccache - cmd /C sccache -V || echo install sccache failed! sccache --stop-server 2> NUL del %SCCACHE_ROOT%\sccache_log.txt @@ -241,6 +239,7 @@ call :cmake || goto cmake_error call :build || goto build_error call :test_whl_pacakage || goto test_whl_pacakage_error call :test_unit || goto test_unit_error +call :test_inference || goto test_inference_error goto:success rem ------PR CI windows check for OPENBLAS/CPU------