aboutsummaryrefslogtreecommitdiff
path: root/src/msi
diff options
context:
space:
mode:
Diffstat (limited to 'src/msi')
-rw-r--r--src/msi/README.md22
-rw-r--r--src/msi/sok.wxs166
2 files changed, 188 insertions, 0 deletions
diff --git a/src/msi/README.md b/src/msi/README.md
new file mode 100644
index 0000000..7d420f5
--- /dev/null
+++ b/src/msi/README.md
@@ -0,0 +1,22 @@
+Generate MSI installer for Windows.
+
+Setup:
+
+ apt-get install wixl
+
+Build (using sok.msi build target):
+
+ ninja sok.msi
+
+Dependencies:
+
+* `SDL2-devel` (from libsdl.org)
+* `SDL2_ttf-devel` (from libsdl.org)
+
+Example (generate by hand):
+
+ # generate sok.msi
+ wixl -o sok.msi \
+ -D BUILD_DIR=../../build-w64 \
+ -D SDL_LIB_DIR=/usr/local/x86_64-w64-mingw32/bin \
+ sok.wxs
diff --git a/src/msi/sok.wxs b/src/msi/sok.wxs
new file mode 100644
index 0000000..2a15cfa
--- /dev/null
+++ b/src/msi/sok.wxs
@@ -0,0 +1,166 @@
+<?xml version='1.0' encoding='utf-8'?>
+<!--
+To build:
+ wixl -o sok.msi \
+ -D BUILD_DIR=../../build-w64 \
+ -D SDL_LIB_DIR=/usr/local/x86_64-w64-mingw32/bin \
+ sok.wxs
+
+GUIDs (wget -qO- https://www.uuidgenerator.net/api/guid/10):
+# 3626b379-ca7b-4fae-990e-b00cdeb0f2d7
+# dd702ed3-2b65-4d05-bc99-205aafbb8c37
+# ca5c1c3c-4bb5-4123-b8ff-e1228e3457eb
+# be925023-1bc1-4e05-a5bf-64b831106651
+# 29d288a3-09f7-408b-8412-8d0e6176a235
+# 8089e94a-61f3-402e-b1b4-6b7346dc96e9
+# 1e8a655d-7370-410c-95f2-2e42c41d9031
+# 67058335-6a4e-4cf0-bc34-c8cc2e2e2578
+# e9383c16-e1cb-432a-b8db-d799c8225c85
+# 58de5bfd-4962-4fbc-a2e7-01da77bd050b
+
+-->
+<Wix xmlns='http://schemas.microsoft.com/wix/2006/wi'>
+ <Product
+ Name='Sokoban'
+ Id='3626b379-ca7b-4fae-990e-b00cdeb0f2d7'
+ UpgradeCode='dd702ed3-2b65-4d05-bc99-205aafbb8c37'
+ Language='1033'
+ Codepage='1252'
+ Version='1.0'
+ Manufacturer='Pablotron'
+ >
+ <Package
+ Id='*'
+ Keywords='Installer'
+ Description="Pablotron Sokoban installer."
+ Comments='Pablotron sokoban.'
+ Manufacturer='Pablotron'
+ InstallerVersion='100'
+ Languages='1033'
+ Compressed='yes'
+ SummaryCodepage='1252'
+ />
+
+ <Media
+ Id='1'
+ Cabinet='sok.cab'
+ EmbedCab='yes'
+ DiskPrompt="CD-ROM #1"
+ />
+
+ <Property
+ Id='DiskPrompt'
+ Value="Pablotron Sokoban 1.0 Installation [1]"
+ />
+
+ <Directory Id='TARGETDIR' Name='SourceDir'>
+ <Directory Id='ProgramFilesFolder' Name='PFiles'>
+ <Directory Id='Pablotron' Name='Pablotron'>
+ <Directory Id='INSTALLDIR' Name='Sokoban 1.0'>
+
+ <Component
+ Id='cmp-sok-exe'
+ Guid='ca5c1c3c-4bb5-4123-b8ff-e1228e3457eb'
+ >
+ <File
+ Id='file-sok-exe'
+ Name='sok.exe'
+ DiskId='1'
+ Source='$(var.BUILD_DIR)/sok.exe'
+ KeyPath='yes'
+ />
+ </Component>
+
+ <Component
+ Id='cmp-solve-exe'
+ Guid='be925023-1bc1-4e05-a5bf-64b831106651'
+ >
+ <File
+ Id='file-solve-exe'
+ Name='solve.exe'
+ DiskId='1'
+ Source='$(var.BUILD_DIR)/solve.exe'
+ KeyPath='yes'
+ />
+ </Component>
+
+ <Component
+ Id='cmp-text-exe'
+ Guid='29d288a3-09f7-408b-8412-8d0e6176a235'
+ >
+ <File
+ Id='file-text-exe'
+ Name='text.exe'
+ DiskId='1'
+ Source='$(var.BUILD_DIR)/text.exe'
+ KeyPath='yes'
+ />
+ </Component>
+
+ <Component
+ Id='cmp-libfreetype-dll'
+ Guid='8089e94a-61f3-402e-b1b4-6b7346dc96e9'
+ >
+ <File
+ Id='file-libfreetype-6-dll'
+ Name='libfreetype-6.dll'
+ DiskId='1'
+ Source='$(var.SDL_LIB_DIR)/libfreetype-6.dll'
+ KeyPath='yes'
+ />
+ </Component>
+
+ <Component
+ Id='cmp-sdl2-ttf-dll'
+ Guid='1e8a655d-7370-410c-95f2-2e42c41d9031'
+ >
+ <File
+ Id='file-sdl2-ttf-dll'
+ Name='SDL2_ttf.dll'
+ DiskId='1'
+ Source='$(var.SDL_LIB_DIR)/SDL2_ttf.dll'
+ KeyPath='yes'
+ />
+ </Component>
+
+ <Component
+ Id='cmp-sdl2-dll'
+ Guid='67058335-6a4e-4cf0-bc34-c8cc2e2e2578'
+ >
+ <File
+ Id='file-sdl2-dll'
+ Name='SDL2.dll'
+ DiskId='1'
+ Source='$(var.SDL_LIB_DIR)/SDL2.dll'
+ KeyPath='yes'
+ />
+ </Component>
+
+ <Component
+ Id='cmp-zlib1-dll'
+ Guid='e9383c16-e1cb-432a-b8db-d799c8225c85'
+ >
+ <File
+ Id='file-zlib1-dll'
+ Name='zlib1.dll'
+ DiskId='1'
+ Source='$(var.SDL_LIB_DIR)/zlib1.dll'
+ KeyPath='yes'
+ />
+ </Component>
+ </Directory>
+ </Directory>
+ </Directory>
+ </Directory>
+
+ <Feature Id='Complete' Level='1'>
+ <ComponentRef Id='cmp-sok-exe'/>
+ <ComponentRef Id='cmp-solve-exe'/>
+ <ComponentRef Id='cmp-text-exe'/>
+ <ComponentRef Id='cmp-libfreetype-dll'/>
+ <ComponentRef Id='cmp-sdl2-ttf-dll'/>
+ <ComponentRef Id='cmp-sdl2-dll'/>
+ <ComponentRef Id='cmp-zlib1-dll'/>
+ </Feature>
+ </Product>
+</Wix>