1 <?xml version=
"1.0" encoding=
"UTF-8"?>
2 <Wix xmlns=
"http://schemas.microsoft.com/wix/2006/wi">
3 <?ifndef env.QEMU_GA_VERSION
?>
4 <?error Environment variable QEMU_GA_VERSION undefined
?>
7 <?ifndef env.QEMU_GA_DISTRO
?>
8 <?error Environment variable QEMU_GA_DISTRO undefined
?>
11 <?ifndef env.QEMU_GA_MANUFACTURER
?>
12 <?error Environment variable QEMU_GA_MANUFACTURER undefined
?>
16 <?error Define Arch to
32 or
64?>
19 <?ifndef var.Mingw_bin
?>
20 <?if $(var.Arch) =
"64"?>
21 <?define Mingw_bin=/usr/x86_64-w64-mingw32/sys-root/mingw/bin
?>
23 <?if $(var.Arch) =
"32"?>
24 <?define Mingw_bin=/usr/i686-w64-mingw32/sys-root/mingw/bin
?>
28 <?if $(var.Arch) =
"64"?>
29 <?define ArchLib=libgcc_s_seh-
1.dll
?>
30 <?define GaProgramFilesFolder=
"ProgramFiles64Folder" ?>
33 <?if $(var.Arch) =
"32"?>
34 <?define ArchLib=libgcc_s_sjlj-
1.dll
?>
35 <?define GaProgramFilesFolder=
"ProgramFilesFolder" ?>
38 <?ifndef var.ArchLib
?>
39 <?error Unexpected Arch value $(var.Arch)
?>
43 Name=
"QEMU guest agent"
45 UpgradeCode=
"{EB6B8302-C06E-4BEC-ADAC-932C68A3A98D}"
46 Manufacturer=
"$(env.QEMU_GA_MANUFACTURER)"
47 Version=
"$(env.QEMU_GA_VERSION)"
49 <?if $(var.Arch) =
32 ?>
50 <Condition Message=
"Error: 32-bit version of Qemu GA can not be installed on 64-bit Windows.">NOT VersionNT64
</Condition>
53 Manufacturer=
"$(env.QEMU_GA_MANUFACTURER)"
54 InstallerVersion=
"200"
57 InstallScope=
"perMachine"
59 <Media Id=
"1" Cabinet=
"qemu_ga.$(env.QEMU_GA_VERSION).cab" EmbedCab=
"yes" />
60 <Property Id=
"WHSLogo">1</Property>
62 DowngradeErrorMessage=
"Error: A newer version of QEMU guest agent is already installed."
65 <Directory Id=
"TARGETDIR" Name=
"SourceDir">
66 <Directory Id=
"$(var.GaProgramFilesFolder)" Name=
"QEMU Guest Agent">
67 <Directory Id=
"qemu_ga_directory" Name=
"Qemu-ga">
68 <Component Id=
"qemu_ga" Guid=
"{908B7199-DE2A-4DC6-A8D0-27A5AE444FEA}">
69 <File Id=
"qemu_ga.exe" Name=
"qemu-ga.exe" Source=
"$(env.BUILD_DIR)/qemu-ga.exe" KeyPath=
"yes" DiskId=
"1"/>
75 DisplayName=
"QEMU Guest Agent"
76 Description=
"QEMU Guest Agent"
84 <ServiceControl Id=
"StartService" Start=
"install" Stop=
"both" Remove=
"uninstall" Name=
"QEMU-GA" Wait=
"no" />
86 <?ifdef var.InstallVss
?>
87 <Component Id=
"qga_vss_dll" Guid=
"{CB19C453-FABB-4BB1-ABAB-6B74F687BFBB}">
88 <File Id=
"qga_vss.dll" Name=
"qga-vss.dll" Source=
"$(env.BUILD_DIR)/qga/vss-win32/qga-vss.dll" KeyPath=
"yes" DiskId=
"1"/>
90 <Component Id=
"qga_vss_tlb" Guid=
"{D8D584B1-59C2-4FB7-A91F-636FF7BFA66E}">
91 <File Id=
"qga_vss.tlb" Name=
"qga-vss.tlb" Source=
"$(env.BUILD_DIR)/qga/vss-win32/qga-vss.tlb" KeyPath=
"yes" DiskId=
"1"/>
94 <Component Id=
"iconv" Guid=
"{35EE3558-D34B-4F0A-B8BD-430FF0775246}">
95 <File Id=
"iconv.dll" Name=
"iconv.dll" Source=
"$(var.Mingw_bin)/iconv.dll" KeyPath=
"yes" DiskId=
"1"/>
97 <Component Id=
"libgcc_arch_lib" Guid=
"{ADD4D07D-4515-4AB6-AF3E-C904961B4BB0}">
98 <File Id=
"libgcc_arch_lib" Name=
"$(var.ArchLib)" Source=
"$(var.Mingw_bin)/$(var.ArchLib)" KeyPath=
"yes" DiskId=
"1"/>
100 <Component Id=
"libglib" Guid=
"{D31BFD83-2773-4B65-B45A-E0D2ADA58679}">
101 <File Id=
"libglib_2.0_0.dll" Name=
"libglib-2.0-0.dll" Source=
"$(var.Mingw_bin)/libglib-2.0-0.dll" KeyPath=
"yes" DiskId=
"1"/>
103 <Component Id=
"libintl" Guid=
"{A641BC2D-A907-4A94-9149-F30ED430878F}">
104 <File Id=
"libintl_8.dll" Name=
"libintl-8.dll" Source=
"$(var.Mingw_bin)/libintl-8.dll" KeyPath=
"yes" DiskId=
"1"/>
106 <Component Id=
"libssp" Guid=
"{7880087B-02B4-4EF6-A5D3-D18F8E3D90E1}">
107 <File Id=
"libssp_0.dll" Name=
"libssp-0.dll" Source=
"$(var.Mingw_bin)/libssp-0.dll" KeyPath=
"yes" DiskId=
"1"/>
109 <Component Id=
"libwinpthread" Guid=
"{6C117C78-0F47-4B07-8F34-6BEE11643829}">
110 <File Id=
"libwinpthread_1.dll" Name=
"libwinpthread-1.dll" Source=
"$(var.Mingw_bin)/libwinpthread-1.dll" KeyPath=
"yes" DiskId=
"1"/>
112 <Component Id=
"registry_entries" Guid=
"{D075D109-51CA-11E3-9F8B-000C29858960}">
113 <RegistryKey Root=
"HKLM"
114 Key=
"Software\$(env.QEMU_GA_MANUFACTURER)\$(env.QEMU_GA_DISTRO)\Tools\QemuGA">
115 <RegistryValue Type=
"string" Name=
"ProductID" Value=
"fb0a0d66-c7fb-4e2e-a16b-c4a3bfe8d13b" />
116 <RegistryValue Type=
"string" Name=
"Version" Value=
"$(env.QEMU_GA_VERSION)" />
123 <Property Id=
"cmd" Value=
"cmd.exe"/>
124 <Property Id=
"REINSTALLMODE" Value=
"amus"/>
126 <?ifdef var.InstallVss
?>
127 <CustomAction Id=
"RegisterCom"
128 ExeCommand='/c
"[qemu_ga_directory]qemu-ga.exe" -s vss-install'
135 <CustomAction Id=
"UnRegisterCom"
136 ExeCommand='/c
"[qemu_ga_directory]qemu-ga.exe" -s vss-uninstall'
145 <Feature Id=
"QEMUFeature" Title=
"QEMU Guest Agent" Level=
"1">
146 <ComponentRef Id=
"qemu_ga" />
147 <?ifdef var.InstallVss
?>
148 <ComponentRef Id=
"qga_vss_dll" />
149 <ComponentRef Id=
"qga_vss_tlb" />
151 <ComponentRef Id=
"iconv" />
152 <ComponentRef Id=
"libgcc_arch_lib" />
153 <ComponentRef Id=
"libglib" />
154 <ComponentRef Id=
"libintl" />
155 <ComponentRef Id=
"libssp" />
156 <ComponentRef Id=
"libwinpthread" />
157 <ComponentRef Id=
"registry_entries" />
160 <InstallExecuteSequence>
161 <?ifdef var.InstallVss
?>
162 <Custom Action=
"UnRegisterCom" After=
"StopServices">Installed
</Custom>
163 <Custom Action=
"RegisterCom" After=
"InstallServices">NOT REMOVE
</Custom>
165 </InstallExecuteSequence>