2 setlocal EnableExtensions
5 if /I "%~1"=="clean" goto clean
7 if not exist "config.h" (
8 echo [ERROR] config.h is missing from the source root.
9 echo Please extract the full source ZIP before building.
13 findstr /n /c:"#define snprintf" "%~dp0libmultihash\multihash.h" "%~dp0libfriidump\win32compat.h" >nul 2>nul
15 echo [ERROR] Legacy snprintf macro still present. Overwrite libmultihash\multihash.h and libfriidump\win32compat.h from this package.
20 if not exist "build-msvc32" mkdir "build-msvc32"
22 call "%~dp0.vscode\msvc32.cmd" cl @"%~dp0msvc32_friidump.rsp"
23 if errorlevel 1 exit /b %ERRORLEVEL%
25 "%~dp0friidump.exe" --help
26 if errorlevel 1 exit /b %ERRORLEVEL%
28 powershell -NoProfile -ExecutionPolicy Bypass -Command "Compress-Archive -Force -Path friidump.exe,docs,README,AUTHORS,COPYING,config.h,msvc32_friidump.rsp,build_msvc32.cmd,.vscode -DestinationPath friidump_msvc32_build_results.zip"
32 if exist "friidump.exe" del /q "friidump.exe"
33 if exist "build-msvc32" rmdir /s /q "build-msvc32"
34 if exist "friidump_msvc32_build_results.zip" del /q "friidump_msvc32_build_results.zip"