jj add wix setup
This commit is contained in:
9
SetupWIX/Config.wxi
Normal file
9
SetupWIX/Config.wxi
Normal file
@@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Include>
|
||||
<?define ProgramName="DD_PROXY_SYNC"?>
|
||||
<?define ProductName="DD Proxy Sync"?>
|
||||
<?define Manufacturer="Digital Data"?>
|
||||
<?define Description="Dienst, der zwischen dem Proxy-Server und dem Main-Server Daten für ADDI syncronisiert"?>
|
||||
<?define Comments="Kommentar wie Copyright-Hinweis"?>
|
||||
<?define UpgradeCode="833FE23D-FAFA-4D80-8777-00BC64BDDDB1"?>
|
||||
</Include>
|
||||
107
SetupWIX/Product.wxs
Normal file
107
SetupWIX/Product.wxs
Normal file
@@ -0,0 +1,107 @@
|
||||
<?include Config.wxi?>
|
||||
|
||||
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi" xmlns:util="http://schemas.microsoft.com/wix/UtilExtension">
|
||||
<Product Id="*" Name="$(var.ProductName)" Language="1031" Codepage="1252" Version="$(var.ProductVersion)" Manufacturer="$(var.Manufacturer)" UpgradeCode="$(var.UpgradeCode)">
|
||||
<Package
|
||||
Id="*"
|
||||
Keywords="Installer"
|
||||
Description="$(var.Description)"
|
||||
Comments="$(var.Comments)"
|
||||
Manufacturer="$(var.Manufacturer)"
|
||||
InstallerVersion="100"
|
||||
Languages="1031"
|
||||
Compressed="yes"
|
||||
SummaryCodepage="1252"
|
||||
/>
|
||||
|
||||
<!-- Muss vorhanden sein, muss nicht geändert werden -->
|
||||
<Media Id='1' Cabinet='$(var.ProgramName).cab' EmbedCab='yes' DiskPrompt='$(var.ProgramName)' />
|
||||
<Property Id='DiskPrompt' Value="$(var.ProgramName) Install" />
|
||||
|
||||
|
||||
<!-- Legt fest ob Downgrades erlaubt sind und die Nachricht, wenn dies versucht wird -->
|
||||
<MajorUpgrade
|
||||
AllowDowngrades="no"
|
||||
AllowSameVersionUpgrades="no"
|
||||
DowngradeErrorMessage="Eine neuere Version von [ProductName] ist bereits installiert. Das Setup wird beendet."
|
||||
/>
|
||||
|
||||
<!-- Legt die Bedingungen für Updates des Programms fest-->
|
||||
<Property Id="PREVIOUSVERSIONSINSTALLED" Secure="yes" />
|
||||
<Upgrade Id="$(var.UpgradeCode)">
|
||||
<UpgradeVersion
|
||||
Minimum="1.0.0.0" Maximum="99.0.0.0"
|
||||
Property="PREVIOUSVERSIONSINSTALLED"
|
||||
IncludeMinimum="yes" IncludeMaximum="no" />
|
||||
</Upgrade>
|
||||
|
||||
<!-- Legt das Icon fest -->
|
||||
<Icon Id="AppIcon" SourceFile="$(var.ProgramName).exe" />
|
||||
<!-- Zeige Icon in Systemsteuerung > Programme entfernen -->
|
||||
<Property Id="ARPPRODUCTICON" Value="AppIcon" />
|
||||
|
||||
<Directory Id="TARGETDIR" Name="SourceDir">
|
||||
<Directory Id="ProgramFilesFolder">
|
||||
<Directory Id="INSTALLDIR" Name="$(var.ProductName)"/>
|
||||
</Directory>
|
||||
</Directory>
|
||||
|
||||
<DirectoryRef Id="INSTALLDIR">
|
||||
<Component Id="MainApplicationExe" Guid="{9C3ECF39-3CE2-4E7A-BF2A-DD48704393ED}">
|
||||
<File Id="MainApplicationExe" Name="$(var.ProgramName).exe" KeyPath="yes" Checksum="yes"/>
|
||||
|
||||
<ServiceInstall
|
||||
Id="ServiceInstaller"
|
||||
Type="ownProcess"
|
||||
Name="$(var.ProgramName)"
|
||||
DisplayName="$(var.ProductName)"
|
||||
Description="$(var.Description)"
|
||||
Start="auto"
|
||||
ErrorControl="normal" />
|
||||
<ServiceControl Id="StartService" Start="install" Stop="both" Remove="uninstall" Name="$(var.ProgramName)" Wait="yes" />
|
||||
</Component>
|
||||
|
||||
<Component Id="RegistryKeys" Guid="{DD65998B-07A6-4CA9-8C93-08E225769ADA}">
|
||||
<RegistryKey Root="HKCU" Key="Software">
|
||||
|
||||
<RegistryKey Key="[Manufacturer]">
|
||||
<RegistryKey Key="[ProductName]" ForceCreateOnInstall="yes" ForceDeleteOnUninstall="yes" Id="REGKEYINSTALLDIR">
|
||||
<RegistryValue Type="string" Value="[INSTALLDIR]" Name="Path" />
|
||||
</RegistryKey>
|
||||
</RegistryKey>
|
||||
|
||||
</RegistryKey>
|
||||
|
||||
<util:RemoveFolderEx Id="RemoveApplicationFolder" On="uninstall" Property="APPLICATIONFOLDER" />
|
||||
</Component>
|
||||
</DirectoryRef>
|
||||
|
||||
<Feature Id="MainApplication" Title="Main Application" Level="1">
|
||||
<ComponentRef Id="MainApplicationExe" />
|
||||
<ComponentRef Id="RegistryKeys"/>
|
||||
</Feature>
|
||||
|
||||
<!-- Legt das Standard-Installationsverzeichnis fest-->
|
||||
<Property Id="WIXUI_INSTALLDIR" Value="INSTALLDIR" />
|
||||
|
||||
<UI>
|
||||
<UIRef Id="WixUI_InstallDir" />
|
||||
<UIRef Id="WixUI_ErrorProgressText" />
|
||||
<Publish Dialog="WelcomeDlg"
|
||||
Control="Next"
|
||||
Event="NewDialog"
|
||||
Value="InstallDirDlg"
|
||||
Order="2">1</Publish>
|
||||
<Publish Dialog="InstallDirDlg"
|
||||
Control="Back"
|
||||
Event="NewDialog"
|
||||
Value="WelcomeDlg"
|
||||
Order="2">1</Publish>
|
||||
</UI>
|
||||
|
||||
<Property Id="APPLICATIONFOLDER">
|
||||
<RegistrySearch Key="Software\[Manufacturer]\[ProductName]" Root="HKCU" Type="raw" Id="APPLICATIONFOLDER_REGSEARCH" Name="Path" />
|
||||
</Property>
|
||||
|
||||
</Product>
|
||||
</Wix>
|
||||
67
SetupWIX/SetupWIX.wixproj
Normal file
67
SetupWIX/SetupWIX.wixproj
Normal file
@@ -0,0 +1,67 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup>
|
||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
|
||||
<ProductVersion>3.9</ProductVersion>
|
||||
<ProjectGuid>ce2dd830-fba9-4bac-b7b3-82f21d52cb6f</ProjectGuid>
|
||||
<SchemaVersion>2.0</SchemaVersion>
|
||||
<OutputName>SetupWIX</OutputName>
|
||||
<OutputType>Package</OutputType>
|
||||
<WixTargetsPath Condition=" '$(WixTargetsPath)' == '' AND '$(MSBuildExtensionsPath32)' != '' ">$(MSBuildExtensionsPath32)\Microsoft\WiX\v3.x\Wix.targets</WixTargetsPath>
|
||||
<WixTargetsPath Condition=" '$(WixTargetsPath)' == '' ">$(MSBuildExtensionsPath)\Microsoft\WiX\v3.x\Wix.targets</WixTargetsPath>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' ">
|
||||
<OutputPath>bin\$(Configuration)\</OutputPath>
|
||||
<IntermediateOutputPath>obj\$(Configuration)\</IntermediateOutputPath>
|
||||
<DefineConstants>Debug</DefineConstants>
|
||||
<LinkerAdditionalOptions>-b "$(SolutionDir)DD_PROXY_SYNC\bin\$(Configuration)" -cultures:de-DE,en-GB,en-US</LinkerAdditionalOptions>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' ">
|
||||
<OutputPath>bin\$(Configuration)\</OutputPath>
|
||||
<IntermediateOutputPath>obj\$(Configuration)\</IntermediateOutputPath>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="Product.wxs" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<WixExtension Include="WixUtilExtension">
|
||||
<HintPath>$(WixExtDir)\WixUtilExtension.dll</HintPath>
|
||||
<Name>WixUtilExtension</Name>
|
||||
</WixExtension>
|
||||
<WixExtension Include="WixUIExtension">
|
||||
<HintPath>$(WixExtDir)\WixUIExtension.dll</HintPath>
|
||||
<Name>WixUIExtension</Name>
|
||||
</WixExtension>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Content Include="Config.wxi" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(WixTargetsPath)" />
|
||||
<!--
|
||||
To modify your build process, add your task inside one of the targets below and uncomment it.
|
||||
Other similar extension points exist, see Wix.targets.
|
||||
<Target Name="BeforeBuild">
|
||||
</Target>
|
||||
<Target Name="AfterBuild">
|
||||
</Target>
|
||||
-->
|
||||
<Target Name="BeforeBuild">
|
||||
<!-- Get the programs assembly version from the .exe file -->
|
||||
<GetAssemblyIdentity AssemblyFiles="..\DD_PROXY_SYNC\bin\$(Configuration)\DD_PROXY_SYNC.exe">
|
||||
<Output TaskParameter="Assemblies" ItemName="AsmInfo" />
|
||||
</GetAssemblyIdentity>
|
||||
<!-- Store the assembly version number in ProductVersion preprocessor variable -->
|
||||
<CreateProperty Value="$(DefineConstants);ProductVersion=%(AsmInfo.Version)">
|
||||
<Output TaskParameter="Value" PropertyName="DefineConstants" />
|
||||
</CreateProperty>
|
||||
<!-- Name the .msi file after the solution platform and assembly version e.g TestService-x86-1.4.0.0.msi -->
|
||||
<CreateProperty Value="$(SolutionName)-$(Platform)-%(AsmInfo.Version)">
|
||||
<Output TaskParameter="Value" PropertyName="TargetName" />
|
||||
</CreateProperty>
|
||||
<!-- Name the .wixpdb file after the solution platform and assembly version e.g TestService-x86-1.4.0.0.msi -->
|
||||
<CreateProperty Value="$(TargetName)$(TargetPdbExt)">
|
||||
<Output TaskParameter="Value" PropertyName="TargetPdbName" />
|
||||
</CreateProperty>
|
||||
</Target>
|
||||
</Project>
|
||||
Reference in New Issue
Block a user