aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn MacFarlane <jgm@berkeley.edu>2013-02-12 19:27:18 -0800
committerJohn MacFarlane <jgm@berkeley.edu>2013-02-12 19:27:18 -0800
commit86dd9f1576f6dab3c254e293134b1ce8b2a6549f (patch)
tree1d7ba55e32ba9980b626d726c42049912136153d
parent35cc1d99ca8c8986869890bdf8de0930b5b3bd3c (diff)
parent7fa4fc150374d6d348e6a4c7b0e513b3eb7c1da9 (diff)
downloadpandoc-86dd9f1576f6dab3c254e293134b1ce8b2a6549f.tar.gz
Merge pull request #748 from sheremetyev/wix-peruser
Install Pandoc per-user on Windows
-rw-r--r--windows/make-windows-installer.bat2
-rw-r--r--windows/pandoc.wxs32
2 files changed, 20 insertions, 14 deletions
diff --git a/windows/make-windows-installer.bat b/windows/make-windows-installer.bat
index 269458dc3..91a31cfb9 100644
--- a/windows/make-windows-installer.bat
+++ b/windows/make-windows-installer.bat
@@ -26,7 +26,7 @@ cd windows
echo Creating msi...
"C:\Program Files\WiX Toolset v3.7\bin\candle.exe" -dVERSION=%VERSION% -ext WixUIExtension pandoc.wxs
if %errorlevel% neq 0 exit /b %errorlevel%
-"C:\Program Files\WiX Toolset v3.7\bin\light.exe" -ext WixUIExtension -out pandoc-%VERSION%.msi pandoc.wixobj
+"C:\Program Files\WiX Toolset v3.7\bin\light.exe" -sw1076 -ext WixUIExtension -out pandoc-%VERSION%.msi pandoc.wixobj
if %errorlevel% neq 0 exit /b %errorlevel%
echo Starting kSign: sign, then quit kSign to complete the build...
"C:\Program Files\kSign\kSign.exe"
diff --git a/windows/pandoc.wxs b/windows/pandoc.wxs
index 1e391d14a..71afa8eb0 100644
--- a/windows/pandoc.wxs
+++ b/windows/pandoc.wxs
@@ -1,31 +1,34 @@
<?xml version="1.0"?>
+<?define UpgradeCode = "A68E8EF6-ABB1-4F22-A3C5-68DFDF0AB562" ?>
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">
<Product Id="*"
- UpgradeCode="A68E8EF6-ABB1-4F22-A3C5-68DFDF0AB562" Name="Pandoc $(var.VERSION)"
+ UpgradeCode="$(var.UpgradeCode)" Name="Pandoc $(var.VERSION)"
Version="$(var.VERSION)" Manufacturer="John MacFarlane"
Language="1033">
- <Package InstallerVersion="200" Compressed="yes"
+ <Package InstallerVersion="200" Compressed="yes" InstallScope="perUser"
Comments="Windows Installer Package" />
<Media Id="1" Cabinet="product.cab" EmbedCab="yes" />
<Property Id="PREVIOUSVERSIONSINSTALLED" Secure="yes" />
- <Upgrade Id="A68E8EF6-ABB1-4F22-A3C5-68DFDF0AB562">
- <UpgradeVersion
- Minimum="0.46.0.0" Maximum="$(var.VERSION)"
- Property="PREVIOUSVERSIONSINSTALLED"
- IncludeMinimum="yes" IncludeMaximum="no" />
+ <Upgrade Id="$(var.UpgradeCode)">
+ <UpgradeVersion Property='PREVIOUSVERSIONSINSTALLED'
+ Minimum='0.0.0.0' IncludeMinimum='yes'
+ Maximum="99.0.0.0" IncludeMaximum="no" />
</Upgrade>
+ <Property Id="ARPURLINFOABOUT" Value="http://johnmacfarlane.net/pandoc/" />
<InstallExecuteSequence>
<RemoveExistingProducts After="InstallFinalize"/>
</InstallExecuteSequence>
<Directory Id="TARGETDIR" Name="SourceDir">
- <Directory Id="DesktopFolder" Name="Desktop" />
<Directory Id="ProgramMenuFolder">
<Directory Id="ApplicationProgramsFolder" Name="Pandoc"/>
</Directory>
- <Directory Id="ProgramFilesFolder">
+ <Directory Id="LocalAppDataFolder">
<Directory Id="INSTALLDIR" Name="Pandoc">
<Component Id="MainExecutable"
- Guid="ECD35082-4C28-49E1-977E-B90FC7C400C7" KeyPath="yes">
+ Guid="ECD35082-4C28-49E1-977E-B90FC7C400C7">
+ <RegistryValue Root="HKCU" Key="Software\John MacFarlane\Pandoc"
+ Name="Version" Type="string" Value="[ProductVersion]" KeyPath="yes"/>
+ <RemoveFolder Id="INSTALLDIR" On="uninstall"/>
<File Id="pandocEXE" Name="pandoc.exe"
Source="..\cabal-dev\bin\pandoc.exe" />
<File Id="pandocCOPYRIGHT" Name="COPYRIGHT.txt"
@@ -33,10 +36,12 @@
<File Id="pandocCOPYING" Name="COPYING.rtf"
Source="..\COPYING.rtf" />
<Environment Id="UpdatePath" Name="PATH" Action="set"
- Part="last" System="yes" Value="[INSTALLDIR]" />
+ Part="last" Value="[INSTALLDIR]" />
</Component>
<Component Id="Documentation"
- Guid="A8D54A76-1A3D-4647-8327-81B69D39D8A3" KeyPath="yes">
+ Guid="A8D54A76-1A3D-4647-8327-81B69D39D8A3">
+ <RegistryValue Root="HKCU" Key="Software\John MacFarlane\Pandoc"
+ Name="DocumentationInstalled" Type="integer" Value="1" KeyPath="yes"/>
<File Id="pandocREADME" Name="Pandoc User's Guide.html"
Source="..\README.html" />
</Component>
@@ -51,7 +56,8 @@
Target="[INSTALLDIR]Pandoc User's Guide.html"
WorkingDirectory="INSTALLDIR" />
<RemoveFolder Id="ApplicationProgramsFolder" On="uninstall"/>
- <RegistryValue Root="HKCU" Key="Software\John MacFarlane\Pandoc" Name="installed" Type="integer" Value="1" KeyPath="yes"/>
+ <RegistryValue Root="HKCU" Key="Software\John MacFarlane\Pandoc"
+ Name="ShortcutInstalled" Type="integer" Value="1" KeyPath="yes"/>
</Component>
</DirectoryRef>
<Feature Id="Complete" Level="1" Title="Pandoc $(var.VERSION)" Description="Complete package" Display="expand" ConfigurableDirectory="INSTALLDIR">