Page MenuHome GnuPG

MSI: Link the MSI package with wine
Open, WishlistPublic

Description

Just so that there is a task for this.

The MSI build process currently builds multiple wixlibs which are basically binary packages contining the files of some components and then as a final step links them together into an MSI package. Linking means calling the tool "light.exe" to combine the various wixlibs into a consistent MSI Database.

While everything up to that final link is done using WINE on linux, the last step always ended up with output like:

51184.480:012c:fixme:file:NtLockFile I/O completion on lock not implemented yet
51185.584:012c:fixme:msi:MsiGetLastErrorRecord 
51185.594:012c:err:msidb:msi_commit_streams failed to write stream L"\430b\4131\4735\443e\4336\41ac\47a8\43e7\482f" (hr = 0x80030102)
51185.594:012c:err:msi:MsiDatabaseCommit Failed to commit streams!
51185.594:012c:fixme:msi:MsiGetLastErrorRecord 
51185.594:012c:fixme:msi:MsiGetLastErrorRecord 
light.exe : error LGHT0216 : An unexpected Win32 exception with error code 0x65B occurred: Function failed

Searching on the Web has shown that other projects run into this too but I could not find a fix, usually it was suggest to the person encountering the problem to use Windows instead. So we use SSH to then log into a Windows Host and run the final link step there. This complicates and slows down the build and makes it harder to reproduce so it would be better if it could be avoided. When I originally started working with wine and wixtools for GnuPG, I could link the GnuPG Wixlib into a GnuPG MSI standalone installer. So it must have something to do with the size, or whatever. The same call with the same binaries works on Windows. I think I have tried nearly everything, no parrelization, no compression, etc. pp. Not even ChatGPT could help.

I think the related source for this in reactos is: https://doxygen.reactos.org/d1/dd4/streams_8c_source.html#l00607

For now I have given up on this again with wine-9.14 and wixtools 3.14 and will just commit the target I have used to test this which can be optionally executed to try it again in the future.