2009
06.11

I started migrating our installers to WiX while at the same time, trying to get my head around it.

I must admit, WiX is pretty damn powerful, and I’m kicking myself for not using this sooner…but there are a few annoyances that I have uncovered while creating an installer…like this one:

http://wix.sourceforge.net/faq.html#Error217

You get this at one point as you add file references to your installer and building it.  What the hell is that?  Seriously, WiX guys, seriously.

I got some more to add, but I need to finish this installer. 

Update 2009.06.11: I finished my installer yesterday afternoon, but it took me a long while to tweak the WiX project settings to build properly on our TeamCity server.  Here are the annoyances I have discovered along the way:

  • The default Wix Project template in Votive, the installer creates a “silent” one–i.e., no UI interaction.  When was the last time you created a silent installer?  That’s right: NEVER.  At the very least you should see an option to change the install location, and to do this you need to add :

<UIRef Id=WixUI_InstallDir/>

This can be attritbuted to me being not a genius, but it took me a while (more than 5 minutes, that is) to realize that my installer is actually working and that it’s just “silent.” I HAD to go back to the WiX Manual to manually add the /UIRef element in the .wxs file.  Would it be difficult to add that as a default and place a comment to remove the UIRef reference if you want a non-interactive installer?  Also, that’s not enough akshully…you also need to add this line to make the minimal UI interaction work:

<Property Id=WIXUI_INSTALLDIR Value=TARGETDIR />

What’s amazing about this is that if you have that line missing, there’s no compile error; not even a warning…instead you get this surprise ”error” dialog box.

  • I REALLLY wish the intellisense magic works with the automatic completion/suggestion of WiX variables and referenced projects like the $(var.{PROJECTNAME}.*).  Right now, the intellisense feature is just MEH to me.  Better yet, how about a more friendly UI editor like what the EntLib folks did for editing .config files?  Is that too much to ask…because WiX is free?  Oh wait.
  • To build properly with our TeamCity servers, I needed to use my own wix.targets file to specify the location of my WixTasks.dll.  I Right-click, New Item…well…no option to create a new wix.targets file…I expect to have it there, with the defaults in the newly-created .targets file…but, no, I had to write one from scratch by copying from somebody else’s blog.
  • Speaking of targets files…did you know that you can use relative paths on /WixTargetsPath, /WixToolPath but NOT on /WixTaskPath (you need to use absolute path)?  My question is: WHY?  (that’s a rhetorical question, BTW)…And shouldn’t these options in the WiX Project Properties anyway?
  • I’m not sure what is the “working directory” for a Wix Project…at first it is the location of the Wix Project file, but as soon as i changed the value of /WixTaskPath to $(SolutionDir)\tool\Wix\3.0\WixTasks.dll, WiX started complaining that it cannot find the other VS Project it references (which breaks the $(var.{PROJECTNAME}.*) references.  Again, I had to open the .wixproj editor outside of Visual Studio to edit the /ProjectReference/@Include
  • OK, WiX is trying to have us move away from the Installer projects that’s built-in Visual Studio…but you know what’s convenient in Visual Studio Installer project that’s missing in Votive?  The ability to detect dependent DLLs of a referenced project and automagically add them to the Installer.  I cannot imagine this to be difficult.

I have a few more complaints, but I’m too tired to type.  Don’t get me wrong, WiX is nice, and once you get over the annoyances, you probably won’t use anything else.  That said, my experience with WiX is akin to being given the opportunity to drive a Corvette, which is pretty powerful in paper and in reality, but then I get into the driver seat only to find out that the seat has dog poop.  Yes, it’s still a Corvette, and you can get rid of the dog poop, but you already sat on it and left a stain on your pants…and you can’t help but wonder if there is more poop once you open the glove compartment

 

2 comments so far

Add Your Comment
  1. That isn’t our design. It’s the way the Windows Intaller implemented validation. It definitely creates headaches but we don’t own that part of the system so we can’t fix it.

    I suppose we could create a whole new implementation but we wouldn’t be able to use the standard ICEs. There’s over a hundred of those so I’d rather spend building something that doesn’t exist over redoing something that is standard MSI SDK functionality and technically the “right way” to go.

    Interest to see if you hae any other suggestions. Preferrably stuff that isn’t broken in the Windows Installer so that we can fix it.

  2. “Preferrably stuff that isn’t broken in the Windows Installer so that we can fix it. ”

    What? well, isn’t the fact there is a *workaround* connotates that there is a solution? i’m not sure why can’t it be simple as executing this registry settings when the (OS == Vista)…and…i don’t know man, can’t you just talk to the Windows Installer project manager to work something out or something? You guys all work for the same company, right? for the love of the kittens, the problem dates back to ’07…

    Oh, and in case you haven’t noticed, i added a boatload of laundry list for you to look at…i hope that’s enough for you to chew on.

Spam Protection by WP-SpamFree