cppcheck/win_installer/cppcheck.wxs

132 lines
7.8 KiB
XML

<?xml version='1.0' encoding='windows-1252'?>
<Wix xmlns='http://schemas.microsoft.com/wix/2006/wi'>
<?include productInfo.wxi ?>
<?include config.wxi ?>
<Product Name='$(var.ProductName)' Id='*' UpgradeCode='$(var.ProductUpgradeCode)'
Language='1033' Codepage='1252' Version='$(var.ProductVersion)' Manufacturer='$(var.ProductManufacturer)'>
<Package Id='*' Keywords='Installer' Description="$(var.ProductName) Setup"
Comments='$(var.ProductDescription)' Manufacturer='$(var.ProductManufacturer)'
InstallerVersion='300' Languages='1033' Compressed='yes' SummaryCodepage='1252'/>
<Media Id='1' Cabinet='Cppcheck.cab' EmbedCab='yes' DiskPrompt='CD-ROM 1' />
<Property Id='DiskPrompt' Value='Cppcheck installation [1]' />
<Directory Id='TARGETDIR' Name='SourceDir'>
<Directory Id='ProgramFilesFolder' Name='PFiles'>
<Directory Id='INSTALLDIR' Name='$(var.ProductNameShort)'>
<Component Id='cppcheck.exe' Guid='$(var.cppcheckGUID)'>
<File Id='cppcheck.exe' Name='cppcheck.exe' DiskId='1' Source='$(var.CliBuildDir)\cppcheck.exe' KeyPath='yes' />
<Environment Id='UpdatePath' Name='PATH' Action='set' System='yes' Part='last' Value='[INSTALLDIR]' />
</Component>
<Component Id='RegistryEntries' Guid='$(var.registrykeysGUID)'>
<RegistryKey Root="HKCU" Key="SOFTWARE\$(var.ProductNameShort)" Action="createAndRemoveOnUninstall">
<RegistryValue Name="InstallationPath" Value="[INSTALLDIR]" Type="string" KeyPath="yes" />
<RegistryValue Name="Version" Value="$(var.ProductVersion)" Type="string" />
</RegistryKey>
</Component>
<Component Id='GuiExecutable' DiskId='1' Guid='$(var.guiGUID)'>
<File Id='cppcheckguiexe' Name='cppcheckgui.exe' Source='$(var.GuiBuildDir)\cppcheck-gui.exe' KeyPath='yes'>
<Shortcut Id='startmenuGui' Directory="ProgramMenuDir" Name='$(var.ProductNameShort)'
WorkingDirectory='INSTALLDIR' Icon="cppcheckgui.exe" IconIndex="0" Advertise="yes" />
</File>
<File Id='libgcc_s_dw2_1_dll' Name='libgcc_s_dw2-1.dll' Source='libgcc_s_dw2-1.dll' />
<File Id='mingwm10dll' Name='mingwm10.dll' Source='mingwm10.dll' />
<File Id='libpcre0dll' Name='libpcre-0.dll' Source='libpcre-0.dll' />
<File Id='qtcore4dll' Name='qtcore4.dll' Source='$(var.QtDllDir)\qtcore4.dll' />
<File Id='qtgui4dll' Name='qtgui4.dll' Source='$(var.QtDllDir)\qtgui4.dll' />
<File Id='qtxml4dll' Name='qtxml4.dll' Source='$(var.QtDllDir)\qtxml4.dll' />
</Component>
<Component Id='GuiTranslations' Guid='$(var.guiTranslationsGUID)'>
<File Id='cppcheck_de.qm' Name='cppcheck_de.qm' Source='$(var.TranslationsDir)\cppcheck_de.qm' />
<File Id='cppcheck_es.qm' Name='cppcheck_es.qm' Source='$(var.TranslationsDir)\cppcheck_es.qm' />
<File Id='cppcheck_fi.qm' Name='cppcheck_fi.qm' Source='$(var.TranslationsDir)\cppcheck_fi.qm' />
<File Id='cppcheck_fr.qm' Name='cppcheck_fr.qm' Source='$(var.TranslationsDir)\cppcheck_fr.qm' />
<File Id='cppcheck_ja.qm' Name='cppcheck_ja.qm' Source='$(var.TranslationsDir)\cppcheck_ja.qm' />
<File Id='cppcheck_nl.qm' Name='cppcheck_nl.qm' Source='$(var.TranslationsDir)\cppcheck_nl.qm' />
<File Id='cppcheck_pl.qm' Name='cppcheck_pl.qm' Source='$(var.TranslationsDir)\cppcheck_pl.qm' />
<File Id='cppcheck_ru.qm' Name='cppcheck_ru.qm' Source='$(var.TranslationsDir)\cppcheck_ru.qm' />
<File Id='cppcheck_sv.qm' Name='cppcheck_sv.qm' Source='$(var.TranslationsDir)\cppcheck_sv.qm' />
<File Id='cppcheck_sr.qm' Name='cppcheck_sr.qm' Source='$(var.TranslationsDir)\cppcheck_sr.qm' />
</Component>
<Component Id='BaseDocs' Guid='$(var.basedocsGUID)'>
<File Id='authors.txt' Name='authors.txt' DiskId='1' Source='..\authors' />
<File Id='readme.txt' Name='readme.txt' DiskId='1' Source='..\readme.txt' />
</Component>
<!-- Cleanup runtime files installed by previous InnoSetup installer.
Also remove old gui.exe which is now cppcheck-gui.exe.
Remove old Swedish translation file which was renamed.
Remove old English translation that is not needed.
Remove locally installed help file that didn't work.
Remove Qt DLLs not needed anymore
-->
<Component Id='InnoSetupCleanup' Guid='4A3F299D-1EE1-468b-814B-D6577F0698CA'>
<RemoveFile Id="msvcp90.dll" On="install" Name="msvcp90.dll" />
<RemoveFile Id="msvcr90.dll" On="install" Name="msvcr90.dll" />
<RemoveFile Id="Microsoft.VC90.CRT.manifest" On="install" Name="Microsoft.VC90.CRT.manifest" />
<RemoveFile Id="gui.exe" On="install" Name="gui.exe" />
<RemoveFile Id="cppcheck_se.qm" On="install" Name="cppcheck_se.qm" />
<RemoveFile Id="cppcheck_en.qm" On="install" Name="cppcheck_en.qm" />
<RemoveFile Id="onlinehelp.qhc" On="install" Name="onlinehelp.qhc" />
<RemoveFile Id="qtclucene4dll" On="install" Name="qtclucene4.dll" />
<RemoveFile Id="qthelp4dll" On="install" Name="qthelp4.dll" />
<RemoveFile Id="qtnetwork4dll" On="install" Name="qtnetwork4.dll" />
<RemoveFile Id="qtsql4dll" On="install" Name="qtsql4.dll" />
</Component>
</Directory>
<!-- <Merge Id="CRT" Language="0" SourceFile="$(var.CrtMergeModule)" DiskId="1" /> -->
</Directory>
<Directory Id='ProgramMenuFolder' Name='Programs' >
<Directory Id='ProgramMenuDir' Name='$(var.ProductName)'>
<Component Id='ProgramMenuDir' Guid='*'>
<RemoveFolder Id='ProgramMenuDir' On='uninstall' />
<RegistryValue Root='HKCU' Key='Software\Cppcheck\$(var.ProductName)' Type='string' Value='' KeyPath='yes' />
</Component>
</Directory>
</Directory>
</Directory>
<Feature Id='Complete' Title='$(var.ProductName)' Description='The complete package.'
Display='expand' Level='1' ConfigurableDirectory='INSTALLDIR' >
<Feature Id='MainProgram' Title='Command line interface' Description='Command line tool' Level='1'>
<ComponentRef Id='cppcheck.exe' />
<ComponentRef Id='RegistryEntries' />
<ComponentRef Id='GuiExecutable' />
<ComponentRef Id='GuiTranslations' />
<ComponentRef Id='BaseDocs' />
<ComponentRef Id='ProgramMenuDir' />
<ComponentRef Id='InnoSetupCleanup' />
</Feature>
<!--
<Feature Id="CRT" AllowAdvertise="no" Display="hidden" Level="1" Title="Microsoft Visual C++ 2008 Runtime Components ">
<MergeRef Id="CRT"/>
</Feature>
-->
</Feature>
<Upgrade Id='$(var.ProductUpgradeCode)'>
<UpgradeVersion OnlyDetect='no'
Property='OLDERVERSIONFOUND'
Minimum='0.0.0'
IncludeMinimum='yes'
Maximum='$(var.ProductVersion)'
IncludeMaximum='no' />
</Upgrade>
<InstallExecuteSequence>
<RemoveExistingProducts After="InstallFinalize">OLDERVERSIONFOUND</RemoveExistingProducts>
</InstallExecuteSequence>
<Property Id="WIXUI_INSTALLDIR" Value="INSTALLDIR" />
<UIRef Id="WixUI_InstallDir"/>
<Icon Id='cppcheckgui.exe' SourceFile='$(var.GuiBuildDir)\cppcheck-gui.exe' />
<WixVariable Id="WixUILicenseRtf" Value="GPLv3.rtf" />
<WixVariable Id="WixUIBannerBmp" Value="Bitmaps\banner.bmp" />
<WixVariable Id="WixUIDialogBmp" Value="Bitmaps\dialog.bmp" />
</Product>
</Wix>