diff options
author | Michael Smith <mikesmiffy128@gmail.com> | 2021-12-30 17:11:57 +0000 |
---|---|---|
committer | Michael Smith <mikesmiffy128@gmail.com> | 2021-12-30 17:16:43 +0000 |
commit | 0da31e9f420e573621712420bf71eb1ca8f6d07f (patch) | |
tree | 41e3d2a192415bfe4a5cc53db2337ada579954a3 /tools | |
parent | f7cc6b4dcc164403d62c9b48ae37f1c4c20f4b4f (diff) |
Add Windows release automation and bump to v0.2v0.2-BETA
Preparing for the January beta release.
Diffstat (limited to 'tools')
-rw-r--r-- | tools/mkbindist.bat | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/tools/mkbindist.bat b/tools/mkbindist.bat new file mode 100644 index 0000000..687761d --- /dev/null +++ b/tools/mkbindist.bat @@ -0,0 +1,27 @@ +:: This file is dedicated to the public domain.
+@echo off
+
+:: make a windows binary release - will eventually need a linux one too, but
+:: worry about that later.
+:: NOTE: requires 7-zip, either in the default installation dir or %SEVENZIP%
+
+call compile.bat || exit /B
+if not exist release\ md release
+if "%SEVENZIP%"=="" set SEVENZIP=C:\Program Files\7-Zip\7z.exe
+setlocal EnableDelayedExpansion
+for /F "tokens=* usebackq" %%x IN (`^(echo VERSION_MAJOR ^& echo VERSION_MINOR^) ^| ^
+ clang -x c -E -include src\version.h - ^| findstr /v #`) do (
+ :: dumb but works:
+ if "!major!"=="" set major=%%x
+ set minor=%%x
+)
+setlocal DisableDelayedExpansion
+set name=sst-v%major%.%minor%-BETA-win32
+md TEMP-%name% || exit /B
+copy sst.dll TEMP-%name%\sst.dll || exit /B
+copy dist\LICENCE.windows TEMP-%name%\LICENCE || exit /B
+pushd TEMP-%name%
+"%SEVENZIP%" a %name%.zip sst.dll LICENCE || exit /B
+move %name%.zip ..\release\%name%.zip
+popd
+rd /s /q TEMP-%name%\ || exit /B
|