make.bat: fix make update not working properly

Git escaped a quote and used all of the cli arguments as the
folder name.

Also fixes:
- Progress on the initial clone so it doesn't appear stuck
- re-detect python after updating libs, so you don't have to run
  make update twice on a fresh clone.
- Hide python not found warning unless the lib folder exists (this
  seemingly got lost in one of the merges)
This commit is contained in:
Ray Molenkamp 2024-02-22 10:40:25 -07:00
parent 5810b6bcde
commit f0bbb0266a
3 changed files with 12 additions and 7 deletions

@ -1,4 +1,4 @@
set BUILD_VS_LIBDIR="lib\windows_x64"
set BUILD_VS_LIBDIR=lib/windows_x64
if NOT "%verbose%" == "" (
echo Library Directory = "%BUILD_VS_LIBDIR%"
@ -15,8 +15,8 @@ if NOT EXIST "%BUILD_VS_LIBDIR%\.git" (
echo Downloading %BUILD_VS_LIBDIR% libraries, please wait.
echo.
:RETRY
"%GIT%" -C "%BLENDER_DIR%" config --local "submodule.%BUILD_VS_LIBDIR%.update" "checkout"
"%GIT%" -C "%BLENDER_DIR%" submodule update --init "%BUILD_VS_LIBDIR%"
"%GIT%" -C "%BLENDER_DIR%\" config --local "submodule.%BUILD_VS_LIBDIR%.update" "checkout"
"%GIT%" -C "%BLENDER_DIR%\" submodule update --progress --init "%BUILD_VS_LIBDIR%"
if errorlevel 1 (
set /p LibRetry= "Error during download, retry? y/n"
if /I "!LibRetry!"=="Y" (

@ -24,7 +24,9 @@ if EXIST %PYTHON% (
)
if NOT EXIST %PYTHON% (
echo Warning: Python not found, there is likely an issue with the library folder
if EXIST %BLENDER_DIR%\lib\windows_x64\ (
echo Warning: Python not found, there is likely an issue with the library folder
)
set PYTHON=""
)

@ -1,8 +1,8 @@
set BUILD_VS_LIBDIR="lib\windows_x64"
set BUILD_VS_LIBDIR=lib/windows_x64
:RETRY
"%GIT%" -C "%BLENDER_DIR%" config --local "submodule.%BUILD_VS_LIBDIR%.update" "checkout"
"%GIT%" -C "%BLENDER_DIR%" submodule update --init "%BUILD_VS_LIBDIR%"
"%GIT%" -C "%BLENDER_DIR%\" config --local "submodule.%BUILD_VS_LIBDIR%.update" "checkout"
"%GIT%" -C "%BLENDER_DIR%\" submodule update --progress --init "%BUILD_VS_LIBDIR%"
if errorlevel 1 (
set /p LibRetry= "Error during update, retry? y/n"
if /I "!LibRetry!"=="Y" (
@ -14,3 +14,6 @@ if errorlevel 1 (
echo.
exit /b 1
)
REM re-detect the dependencies after updating the libraries so any python version
REM changes are accounted for.
call "%~dp0\find_dependencies.cmd"