From fc6cc8fb2b9cbc97ccd6a74c8953cc1920013141 Mon Sep 17 00:00:00 2001 From: Simon Tatham Date: Thu, 10 Mar 2016 18:37:24 +0000 Subject: Use WiX to generate an MSI-based Puzzles installer. I've reused most of the install script I wrote for PuTTY recently, minus the selectable-features dialog, and plus some preliminary Mason templating to automatically build the right set of puzzle binaries into the installer. Stable GUIDs are autogenerated by the same technique I use in PuTTY's Visual Studio project file generation: hash a fixed pile of randomly generated bits (that is, randomly generated _once_ and used forever) with each filename or other identifier and use those as your random number source. --- Buildscr | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'Buildscr') diff --git a/Buildscr b/Buildscr index 3097df5..537e9c0 100644 --- a/Buildscr +++ b/Buildscr @@ -53,6 +53,7 @@ enddelegate in puzzles do make -f Makefile.doc clean in puzzles do make -f Makefile.doc chm in puzzles do make -f Makefile.doc # build help file for installer +in puzzles do mason.pl --args '{"version":"$(Version)","descfile":"gamedesc.txt"}' winwix.mc > puzzles.wxs in puzzles do perl winiss.pl $(Version) gamedesc.txt > puzzles.iss delegate windows # Ignore the poorly controlled return value from HHC, and instead @@ -67,12 +68,14 @@ delegate windows # program name, and that it can take multiple .exe filename # arguments and sign them all in place. ifneq "$(winsigncode)" "" in puzzles do $(winsigncode) -i http://www.chiark.greenend.org.uk/~sgtatham/puzzles/ *.exe - # Build installer. + # Build installers. + in puzzles with wix do/win candle puzzles.wxs && light -ext WixUIExtension -sval puzzles.wixobj in puzzles with innosetup do/win iscc puzzles.iss - ifneq "$(winsigncode)" "" in puzzles do $(winsigncode) -i http://www.chiark.greenend.org.uk/~sgtatham/puzzles/ -n "Simon Tatham's Portable Puzzle Collection Installer" Output/setup.exe + ifneq "$(winsigncode)" "" in puzzles do $(winsigncode) -i http://www.chiark.greenend.org.uk/~sgtatham/puzzles/ -n "Simon Tatham's Portable Puzzle Collection Installer" puzzles.msi Output/setup.exe return puzzles/puzzles.chm return puzzles/*.exe return puzzles/Output/setup.exe + return puzzles/puzzles.msi enddelegate in puzzles do chmod +x *.exe @@ -174,6 +177,7 @@ deliver puzzles/puzzles.chm $@ deliver puzzles/puzzles.hlp $@ deliver puzzles/puzzles.cnt $@ deliver puzzles/puzzles.zip $@ +deliver puzzles/puzzles.msi puzzles-$(Version)-installer.msi deliver puzzles/Output/setup.exe puzzles-$(Version)-installer.exe deliver puzzles/*.jar java/$@ deliver puzzles/js/*.js js/$@ -- cgit v1.1