From 0da31e9f420e573621712420bf71eb1ca8f6d07f Mon Sep 17 00:00:00 2001 From: Michael Smith Date: Thu, 30 Dec 2021 17:11:57 +0000 Subject: Add Windows release automation and bump to v0.2 Preparing for the January beta release. --- .gitignore | 5 ++++- LICENCE | 5 ++++- dist/LICENCE.linux | 47 +++++++++++++++++++++++++++++++++++++++++++++++ dist/LICENCE.windows | 47 +++++++++++++++++++++++++++++++++++++++++++++++ src/sst.c | 2 +- src/version.h | 6 +++--- tools/mkbindist.bat | 27 +++++++++++++++++++++++++++ 7 files changed, 133 insertions(+), 6 deletions(-) create mode 100644 dist/LICENCE.linux create mode 100644 dist/LICENCE.windows create mode 100644 tools/mkbindist.bat diff --git a/.gitignore b/.gitignore index 6861589..5cfdbc5 100644 --- a/.gitignore +++ b/.gitignore @@ -5,4 +5,7 @@ /compile_commands.json # a place to plonk crap you don't wanna commit yet -/junk +/junk/ + +# where release archives get plonked +/release/ diff --git a/LICENCE b/LICENCE index 76ade89..2199378 100644 --- a/LICENCE +++ b/LICENCE @@ -24,4 +24,7 @@ Files under src/3p/ are written and licensed by third parties. See the copyright notices in and alongside those files for details of authorship and relevant redistribution rights. Some - but not all - of this third party code is incorporated into binary builds (sst.dll or sst.so). Please take care when -redistributing binaries to respect all the relevant copyright notices. +redistributing binaries to respect all the relevant copyright notices. Also note +that the LICENCE.windows and LICENCE.linux files under dist/ are used for +official binary release archives, but will need to be modified if other code is +incorporated into a binary. diff --git a/dist/LICENCE.linux b/dist/LICENCE.linux new file mode 100644 index 0000000..1525816 --- /dev/null +++ b/dist/LICENCE.linux @@ -0,0 +1,47 @@ +Source Speedrun Tools is released under the following copyright licence: +================================================================================ +Copyright © 2021 Michael Smith +Copyright © 2021 Willian Henrique + +Permission to use, copy, modify, and/or distribute this software for any purpose +with or without fee is hereby granted, provided that the above copyright notice +and this permission notice appear in all copies. + +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH +REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND +FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, +INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS +OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER +TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF +THIS SOFTWARE. +================================================================================ + +sst.so also includes code from the udis86 project, licensed as follows: +================================================================================ +Copyright © 2002-2009 Vivek Thampi +All rights reserved. + +Redistribution and use in source and binary forms, with or without modification, +are permitted provided that the following conditions are met: + +* Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. + +* Redistributions in binary form must reproduce the above copyright notice, this + list of conditions and the following disclaimer in the documentation and/or + other materials provided with the distribution. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND +ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR +ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON +ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +================================================================================ + +Please respect these terms when distributing copies of sst.so - doing so is as +simple as keeping this LICENCE file in place. Thanks, and have fun! :^) diff --git a/dist/LICENCE.windows b/dist/LICENCE.windows new file mode 100644 index 0000000..2d4bd0f --- /dev/null +++ b/dist/LICENCE.windows @@ -0,0 +1,47 @@ +Source Speedrun Tools is released under the following copyright licence: +================================================================================ +Copyright © 2021 Michael Smith +Copyright © 2021 Willian Henrique + +Permission to use, copy, modify, and/or distribute this software for any purpose +with or without fee is hereby granted, provided that the above copyright notice +and this permission notice appear in all copies. + +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH +REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND +FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, +INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS +OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER +TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF +THIS SOFTWARE. +================================================================================ + +sst.dll also includes code from the udis86 project, licensed as follows: +================================================================================ +Copyright © 2002-2009 Vivek Thampi +All rights reserved. + +Redistribution and use in source and binary forms, with or without modification, +are permitted provided that the following conditions are met: + +* Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. + +* Redistributions in binary form must reproduce the above copyright notice, this + list of conditions and the following disclaimer in the documentation and/or + other materials provided with the distribution. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND +ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR +ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON +ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +================================================================================ + +Please respect these terms when distributing copies of sst.dll - doing so is as +simple as keeping this LICENCE file in place. Thanks, and have fun! :^) diff --git a/src/sst.c b/src/sst.c index 176d5fb..94e1661 100644 --- a/src/sst.c +++ b/src/sst.c @@ -161,7 +161,7 @@ nc: gamedata_init(); } e: con_colourmsg(RGBA(64, 255, 64, 255), - NAME " v" VERSION " successfully loaded"); + LONGNAME " v" VERSION " successfully loaded"); con_colourmsg(RGBA(255, 255, 255, 255), " for game "); con_colourmsg(RGBA(0, 255, 255, 255), "%s\n", gameinfo_title); return true; diff --git a/src/version.h b/src/version.h index b75b78f..605eba7 100644 --- a/src/version.h +++ b/src/version.h @@ -1,5 +1,5 @@ #define NAME "SST" -#define LONGNAME "Source Speedrun Tools" +#define LONGNAME "Source Speedrun Tools Beta" #define VERSION_MAJOR 0 -#define VERSION_MINOR 1 -#define VERSION "Beta 0.1" +#define VERSION_MINOR 2 +#define VERSION "0.2" 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 -- cgit v1.2.3