Build MSI in Wine

*爱你&永不变心* 提交于 2019-12-01 02:19:18
Hib Eris

You can use a combination of Wine, Mono and WiX to create .msi packages on Linux.

For openSUSE, I have created a wrapper package called wixwine which gives you the 'candle' and 'light' commands from the Windows Installer XML (WiX) toolset ready to use on Linux.

You can find my wixwine package here

I just released v0.01 of msitools, a collection of utilities to inspect and create Windows Installer files. It is based on the Wine code, but ported to POSIX.

You can find the source and binary packages at http://bonzini.fedorapeople.org/ - unfortunately you will need to build libgsf from git, because I found a bug and no released version has the fix as of now. The linked page has Fedora RPMs with the fix.

$ msiinfo streams ~/download/Firefox-16.0.2-it.msi 
Binary.New
Binary.Up
Binary.info
Binary.dlgbmp
Binary.CustomBin
Binary.bannrbmp
Binary.completi
Binary.custicon
Binary.exclamic
Binary.insticon
Binary.removico
Binary.repairic
_MAKEMSI_Cabs.MM01.cab
Binary.BannerGraphic.BMP
Icon.firefox.16.0.2.0.ico.exe
DigitalSignature
SummaryInformation
$ msiinfo extract ~/download/Firefox-16.0.2-it.msi _MAKEMSI_Cabs.MM01.cab > firefox.cab
$ cabextract -l firefox.cab
Viewing cabinet: firefox.cab
 File size | Date       Time     | Name
-----------+---------------------+-------------
    917984 | 24.10.2012 12:50:38 | firefox.exe
     18912 | 24.10.2012 12:50:38 | AccessibleMarshal.dll

There is a companion utility msibuild to build MSIs. It is very low-level, but you can use the two tools together to make small changes to an MSI you already made on Windows.

update: now hosted at https://live.gnome.org/msitools, it also has a tool (wixl) that supports a subset of the WiX XML. Requires libgsf 1.14.25 or newer. Fedora 18 and newer have it packaged.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!