From 83090b5e66f4e67f5e084401722d57dcfc37269d Mon Sep 17 00:00:00 2001 From: thexai <58434170+thexai@users.noreply.github.com> Date: Sat, 11 Mar 2023 18:59:49 +0100 Subject: [Windows][build ffmpeg] more robust build scripts --- tools/buildsteps/windows/make-mingwlibs.bat | 3 ++- tools/buildsteps/windows/prepare-env.bat | 8 +++----- 2 files changed, 5 insertions(+), 6 deletions(-) (limited to 'tools') diff --git a/tools/buildsteps/windows/make-mingwlibs.bat b/tools/buildsteps/windows/make-mingwlibs.bat index 428ad169fc..62c41f07d0 100644 --- a/tools/buildsteps/windows/make-mingwlibs.bat +++ b/tools/buildsteps/windows/make-mingwlibs.bat @@ -5,8 +5,9 @@ PUSHD %~dp0\..\..\.. SET WORKDIR=%CD% POPD -REM recreates ffmpeg build dir in case it does not exist +REM recreates clean ffmpeg build dir SET BUILD_DIR=%WORKDIR%\project\BuildDependencies\build +IF EXIST %BUILD_DIR% rmdir %BUILD_DIR% /S /Q IF NOT EXIST %BUILD_DIR% mkdir %BUILD_DIR% SET PROMPTLEVEL=prompt diff --git a/tools/buildsteps/windows/prepare-env.bat b/tools/buildsteps/windows/prepare-env.bat index abafafbfdd..c739726bf2 100644 --- a/tools/buildsteps/windows/prepare-env.bat +++ b/tools/buildsteps/windows/prepare-env.bat @@ -10,6 +10,9 @@ cd %WORKSPACE% rem clean the BUILD_WIN32 at first to avoid problems with possible git files in there IF EXIST %WORKSPACE%\project\Win32BuildSetup\BUILD_WIN32 rmdir %WORKSPACE%\project\Win32BuildSetup\BUILD_WIN32 /S /Q +rem also clean 'build' dir used to build ffmpeg as git clean has trouble to remove some times +IF EXIST %WORKSPACE%\project\BuildDependencies\build rmdir %WORKSPACE%\project\BuildDependencies\build /S /Q + rem we assume git in path as this is a requirement rem git clean the untracked files and directories rem but keep the downloaded dependencies @@ -18,8 +21,3 @@ SET GIT_CLEAN_CMD=git clean -xffd -e "project/BuildDependencies/downloads" -e "p ECHO running %GIT_CLEAN_CMD% %GIT_CLEAN_CMD% - -REM 'build' dir is necessary to extract ffmpeg code -REM we prevents missing under certain circumstances (early creation) -SET BUILD_FFMPEG=%WORKSPACE%\project\BuildDependencies\build -IF NOT EXIST %BUILD_FFMPEG% mkdir %BUILD_FFMPEG% -- cgit v1.2.3