Developing cabal2wix - building Windows installers automatically
ndmitchell at gmail.com
Sun Aug 5 19:04:30 EDT 2007
> I decided to try to build a cabal -> wix converter, cabal2wix, to make
> it easier to generate Windows installers for cabal-packages. My main
> target is ghc-compiled libraries. There are few issues I've ran into
> and I'd appreciate any comments on them.
I found wix annoying, and chose to use InnoSetup instead, following on
from Duncan's use of it in Gtk2hs. Inno can't do .msi's.
> I'll try to publish the darcs repo somewhere if there's interest.
If there was some way to get Hugs and GHC installers out of it,
possibly with a fake cabal file or something, that would be lovely!
Perhaps a System.Installer.Wix library that all could use?
> Cabal puts (at least) docs under Program Files\Common Files - this
> separates docs from other parts of the program by logical placing,
> which is pretty annoying if you need to offer way to relocate
> installation (say to user's home directory). I am considering moving
> docs next to library files in installers cabal2wix generates.
I would very much like it if runhaskell Setup install, and running
your installer generator did the same thing.
> I'd like not to use all possible directory flags at configure time,
> because it is impossible to know how different packages react to them.
> (currently cabal2wix assumes no directories were changed.)
I think you can currently assume no Windows user has ever successfully
> Issue 4:
> There is no proper registry keys for finding compiler installation.
> Neil's installer adds HKCU\Software\Haskell\GHC\InstallDir. I'd much
> prefer if the registry key path contained ghc version in it, and
> HKLM might be preferable on some multi-user machines.
I copied what the previous installer had, and we only no what the
previous installer had because Duncan was relying on it for Gtk2hs
(the previous installer is closed source). Make a concrete suggestion,
file it as a GHC bug and I'm sure it can be done/
> My tentative proposal: Use HKLM if "all users" install, HKCU otherwise.
> Use \Software\Haskell\COMPILER\VERSION\InstallDir for storing path to
> base location of installed compiler. (i.e. it shouldn't point to
> Small issues:
> * License file is not installed.
On Windows, I doubt anyone cares :-)
Thanks for doing this, it has been something I've been meaning to get
to for ages.
More information about the cabal-devel