Blame |
Last modification |
View Log
| Download
| RSS feed
setlocal enableextensions enabledelayedexpansion
rem // make sure we have the tools we need
for %%v in (250 240 230 220 210 200 190 180 170 160 150 140 130 120 110 100 90 80
) do (
if exist "
!VS%%vCOMNTOOLS!..\..\VC\Auxiliary\Build\vcvarsall.bat" ( call "!VS%%vCOMNTOOLS!..\..\VC\Auxiliary\Build\vcvarsall.bat" ) else if exist "!VS%%vCOMNTOOLS!..\..\VC\vcvarsall.bat" call "!VS%%vCOMNTOOLS!..\..\VC\vcvarsall.bat"
)
if not defined VCINSTALLDIR
echo No Microsoft C compiler was found on your system. Please install Visual Studio.
& exit /b 1
)
cl.exe 2
>&1
|powershell -noprofile -command "
($Input
|Select-Object -First 1
) -replace '.+\s
(.+
)','$1'"
> "
%TEMP%\target-arch.txt"
& set /p UNAME_M=
< "
%TEMP%\target-arch.txt"
& del /f "
%TEMP%\target-arch.txt"
rem // common compiler flags (use "-Od -DEBUG" for debug)
rem // create an empty build directory and enter it
rmdir /s /q .build\minismackerplay
> nul 2
>&1
cd .build\minismackerplay
rem // build minismackerplay
echo Building minismackerplay...
cl -nologo ^
-I../../lib/SDL2 ^
-I../../lib/miniaudio/include/miniaudio ^
-I../../lib/libsmacker ^
../../minismackerplay.c ^
../../lib/miniaudio/miniaudio.c ^
../../lib/libsmacker/smacker.c ^
../../lib/libsmacker/smk_bitstream.c ^
../../lib/libsmacker/smk_hufftree.c ^
../../lib/SDL2/SDL2.lib ^
-o minismackerplay.exe
|| goto :
end
copy /b /y minismackerplay.exe ..\..\minismackerplay.
%UNAME_S%-
%UNAME_M%.exe
|| goto :
end
:end