Skip to content
This repository has been archived by the owner on Jun 19, 2021. It is now read-only.

Driver isn't being installed reliably on Windows #18

Open
NoahAndrews opened this issue Dec 9, 2016 · 6 comments
Open

Driver isn't being installed reliably on Windows #18

NoahAndrews opened this issue Dec 9, 2016 · 6 comments
Milestone

Comments

@NoahAndrews
Copy link
Contributor

No description provided.

@NoahAndrews NoahAndrews changed the title Driver isn't being installed reliably Driver isn't being installed reliably on Windows Dec 9, 2016
@NoahAndrews
Copy link
Contributor Author

I haven't tested on a wide range of machines or anything, but I believe Wix is going to be far more robust in the area of driver installation. Whereas we had NSIS running an external utility to install the driver, and then failing to reliably show its output, Wix has driver installation built-in natively, and can tell you exactly why the driver installation failed if that happens.

I have a huge part of the work to moving to Wix done already, which can be seen here (comparison). The installer I built from that repo succeeded in installing the driver in a VM where the NSIS installer failed to do so. Still lots to be done though, like a proper installation GUI and possibly fixing the build for other platforms.

Wix is more complicated than NSIS. It is a wrapper for the Windows Installer system, and so it produces .msi files rather than .exe files (which can be wrapped using its bootsrapper tool Burn). Unlike NSIS installers, which executes a series of steps, .msi files tell Windows "Here is precisely what I want everything to look like. You handle it." This results in a system where you have a huge XML configuration file where you have to give every single file a globally unique ID, and tell it exactly where it should end up in the file system. You also have to be careful about managing the GUIDs between updates. In exchange, you get flexibility, better reliability, and better integration with Windows, allowing for things like automated repair and shared libraries between applications. Wix is very stable, Microsoft Office even uses it for its installer.

I'm looking forward to hearing what you guys think about the possibility of switching, as well as the code I've written in that branch.

@skullydazed
Copy link
Member

I haven't had a chance to review that code, but I did want to say that I'm totally open to moving to Wix. If managing the GUID's is tricky I think we should have some documentation about how to do that.

@NoahAndrews
Copy link
Contributor Author

NoahAndrews commented Dec 10, 2016

I'll make sure that happens

@NoahAndrews
Copy link
Contributor Author

The other thing that will be tricky about maintaining the installer is that nearly all of the files it is copying belong to Electron, not our code (I configured electron-packager to put almost all of our code in a single .asar file to make installer maintenance as easy as possible). What we should probably do is lock down the electron version, and update it manually, verifying that new versions don't add or remove any new files.

@NoahAndrews
Copy link
Contributor Author

Initial UI is implemented. You can try it out here: https://github.com/NoahAndrews/qmk_firmware_flasher/releases/tag/v0.6.0

@NoahAndrews
Copy link
Contributor Author

You can see a list of things that I know need to happen with the new installer here: https://github.com/NoahAndrews/qmk_firmware_flasher/issues.

There's a fair amount of research about WiX in there too. There's a lot to learn.

@skullydazed skullydazed added this to the v0.7 milestone Dec 20, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants