http://bugs.winehq.org/show_bug.cgi?id=7402
------- Additional Comments From truiken@gmail.com 2007-12-02 22:11 ------- manual:
$ msiexec -regserver
With the current way wineprefixcreate loads wine.inf and sets up the current configuration, msiexec's regserver is called before the proper SCM registry entries exist, thus the call to OpenSCManager fails. The patch I sent to add msiexec registration was preceded by a patch that made wineprefixcreate use advpack instead of setupapi to load wine.inf, but that was silently rejected. Using advpack would allow us to use the RunPostSetupCommands after all the registry entries have been created. This is the best solution, but Alexandre hasn't accepted it so far. The other possible solution is to check if the right registry keys exist in OpenSCManager and create them if they don't, but native doesn't do this and it's pretty hacky.