aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRob Mensching <rob@firegiant.com>2018-01-01 10:30:42 -0800
committerRob Mensching <rob@firegiant.com>2018-01-01 22:47:02 -0800
commit60d7baefb4e87bf0ddaae58a653faee0be0429f6 (patch)
treee520865fd6da2368c5d33a4c98cca457bd8a8343
parent9c66865ab3e4b3c4cbcb721e22fd668dd4350afa (diff)
downloadwix-60d7baefb4e87bf0ddaae58a653faee0be0429f6.tar.gz
wix-60d7baefb4e87bf0ddaae58a653faee0be0429f6.tar.bz2
wix-60d7baefb4e87bf0ddaae58a653faee0be0429f6.zip
Initial code commit
-rw-r--r--NetFx.wixext.sln59
-rw-r--r--appveyor.cmd13
-rw-r--r--appveyor.yml29
-rw-r--r--nuget.config16
-rw-r--r--src/Cpp.Build.props101
-rw-r--r--src/Directory.Build.props22
-rw-r--r--src/FindLocalWix.props10
-rw-r--r--src/ca/cost.h7
-rw-r--r--src/ca/dllmain.cpp26
-rw-r--r--src/ca/netfxca.cpp823
-rw-r--r--src/ca/netfxca.def8
-rw-r--r--src/ca/netfxca.vcxproj70
-rw-r--r--src/ca/packages.config6
-rw-r--r--src/ca/precomp.h13
-rw-r--r--src/test/WixToolsetTest.Netfx/NetfxExtensionFixture.cs33
-rw-r--r--src/test/WixToolsetTest.Netfx/TestData/UsingNativeImage/Package.en-us.wxl11
-rw-r--r--src/test/WixToolsetTest.Netfx/TestData/UsingNativeImage/Package.wxs22
-rw-r--r--src/test/WixToolsetTest.Netfx/TestData/UsingNativeImage/PackageComponents.wxs13
-rw-r--r--src/test/WixToolsetTest.Netfx/TestData/UsingNativeImage/example.txt1
-rw-r--r--src/test/WixToolsetTest.Netfx/WixToolsetTest.Netfx.csproj40
-rw-r--r--src/wixext/NetFxCompiler.cs159
-rw-r--r--src/wixext/NetFxDecompiler.cs139
-rw-r--r--src/wixext/NetFxExtensionData.cs25
-rw-r--r--src/wixext/NetfxExtensionFactory.cs18
-rw-r--r--src/wixext/NetfxWindowsInstallerBackendExtension.cs27
-rw-r--r--src/wixext/Tuples/NetFxNativeImageTuple.cs65
-rw-r--r--src/wixext/Tuples/NetfxTupleDefinitions.cs27
-rw-r--r--src/wixext/WixToolset.Netfx.wixext.csproj35
-rw-r--r--src/wixext/WixToolset.Netfx.wixext.targets11
-rw-r--r--src/wixext/netfx.xsd235
-rw-r--r--src/wixlib/NetFx1.1.wxs192
-rw-r--r--src/wixlib/NetFx1.wxs31
-rw-r--r--src/wixlib/NetFx2.wxs201
-rw-r--r--src/wixlib/NetFx3.5.wxs241
-rw-r--r--src/wixlib/NetFx3.wxs195
-rw-r--r--src/wixlib/NetFx4.5.wxs274
-rw-r--r--src/wixlib/NetFx4.wxs543
-rw-r--r--src/wixlib/NetFx451.wxs96
-rw-r--r--src/wixlib/NetFx452.wxs95
-rw-r--r--src/wixlib/NetFx46.wxs96
-rw-r--r--src/wixlib/NetFx461.wxs95
-rw-r--r--src/wixlib/NetFx462.wxs95
-rw-r--r--src/wixlib/NetFxExtension.wxs39
-rw-r--r--src/wixlib/NetFxExtension_Platform.wxi28
-rw-r--r--src/wixlib/NetFxExtension_x86.wxs8
-rw-r--r--src/wixlib/caSuffix.wxi28
-rw-r--r--src/wixlib/netfx.wixproj53
-rw-r--r--src/wixlib/packages.config6
-rw-r--r--version.json11
49 files changed, 4391 insertions, 0 deletions
diff --git a/NetFx.wixext.sln b/NetFx.wixext.sln
new file mode 100644
index 00000000..58578847
--- /dev/null
+++ b/NetFx.wixext.sln
@@ -0,0 +1,59 @@
1
2Microsoft Visual Studio Solution File, Format Version 12.00
3# Visual Studio 15
4VisualStudioVersion = 15.0.27130.2010
5MinimumVisualStudioVersion = 15.0.26124.0
6Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "netfxca", "src\ca\netfxca.vcxproj", "{F72D34CA-48DA-4DFD-91A9-A0C78BEF6981}"
7EndProject
8Project("{930C7802-8A8C-48F9-8165-68863BCCD9DD}") = "netfx", "src\wixlib\netfx.wixproj", "{45E4A6AC-3190-4E17-83F0-9935FFA5DC2B}"
9EndProject
10Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "WixToolset.Netfx.wixext", "src\wixext\WixToolset.Netfx.wixext.csproj", "{F774E291-0563-4DDD-B873-F5C31683CF4B}"
11EndProject
12Global
13 GlobalSection(SolutionConfigurationPlatforms) = preSolution
14 Debug|Any CPU = Debug|Any CPU
15 Debug|x64 = Debug|x64
16 Debug|x86 = Debug|x86
17 Release|Any CPU = Release|Any CPU
18 Release|x64 = Release|x64
19 Release|x86 = Release|x86
20 EndGlobalSection
21 GlobalSection(ProjectConfigurationPlatforms) = postSolution
22 {F72D34CA-48DA-4DFD-91A9-A0C78BEF6981}.Debug|Any CPU.ActiveCfg = Debug|Win32
23 {F72D34CA-48DA-4DFD-91A9-A0C78BEF6981}.Debug|x64.ActiveCfg = Debug|Win32
24 {F72D34CA-48DA-4DFD-91A9-A0C78BEF6981}.Debug|x86.ActiveCfg = Debug|Win32
25 {F72D34CA-48DA-4DFD-91A9-A0C78BEF6981}.Debug|x86.Build.0 = Debug|Win32
26 {F72D34CA-48DA-4DFD-91A9-A0C78BEF6981}.Release|Any CPU.ActiveCfg = Release|Win32
27 {F72D34CA-48DA-4DFD-91A9-A0C78BEF6981}.Release|x64.ActiveCfg = Release|Win32
28 {F72D34CA-48DA-4DFD-91A9-A0C78BEF6981}.Release|x86.ActiveCfg = Release|Win32
29 {F72D34CA-48DA-4DFD-91A9-A0C78BEF6981}.Release|x86.Build.0 = Release|Win32
30 {45E4A6AC-3190-4E17-83F0-9935FFA5DC2B}.Debug|Any CPU.ActiveCfg = Debug|x86
31 {45E4A6AC-3190-4E17-83F0-9935FFA5DC2B}.Debug|x64.ActiveCfg = Debug|x64
32 {45E4A6AC-3190-4E17-83F0-9935FFA5DC2B}.Debug|x64.Build.0 = Debug|x64
33 {45E4A6AC-3190-4E17-83F0-9935FFA5DC2B}.Debug|x86.ActiveCfg = Debug|x86
34 {45E4A6AC-3190-4E17-83F0-9935FFA5DC2B}.Debug|x86.Build.0 = Debug|x86
35 {45E4A6AC-3190-4E17-83F0-9935FFA5DC2B}.Release|Any CPU.ActiveCfg = Release|x86
36 {45E4A6AC-3190-4E17-83F0-9935FFA5DC2B}.Release|x64.ActiveCfg = Release|x64
37 {45E4A6AC-3190-4E17-83F0-9935FFA5DC2B}.Release|x64.Build.0 = Release|x64
38 {45E4A6AC-3190-4E17-83F0-9935FFA5DC2B}.Release|x86.ActiveCfg = Release|x86
39 {45E4A6AC-3190-4E17-83F0-9935FFA5DC2B}.Release|x86.Build.0 = Release|x86
40 {F774E291-0563-4DDD-B873-F5C31683CF4B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
41 {F774E291-0563-4DDD-B873-F5C31683CF4B}.Debug|Any CPU.Build.0 = Debug|Any CPU
42 {F774E291-0563-4DDD-B873-F5C31683CF4B}.Debug|x64.ActiveCfg = Debug|Any CPU
43 {F774E291-0563-4DDD-B873-F5C31683CF4B}.Debug|x64.Build.0 = Debug|Any CPU
44 {F774E291-0563-4DDD-B873-F5C31683CF4B}.Debug|x86.ActiveCfg = Debug|Any CPU
45 {F774E291-0563-4DDD-B873-F5C31683CF4B}.Debug|x86.Build.0 = Debug|Any CPU
46 {F774E291-0563-4DDD-B873-F5C31683CF4B}.Release|Any CPU.ActiveCfg = Release|Any CPU
47 {F774E291-0563-4DDD-B873-F5C31683CF4B}.Release|Any CPU.Build.0 = Release|Any CPU
48 {F774E291-0563-4DDD-B873-F5C31683CF4B}.Release|x64.ActiveCfg = Release|Any CPU
49 {F774E291-0563-4DDD-B873-F5C31683CF4B}.Release|x64.Build.0 = Release|Any CPU
50 {F774E291-0563-4DDD-B873-F5C31683CF4B}.Release|x86.ActiveCfg = Release|Any CPU
51 {F774E291-0563-4DDD-B873-F5C31683CF4B}.Release|x86.Build.0 = Release|Any CPU
52 EndGlobalSection
53 GlobalSection(SolutionProperties) = preSolution
54 HideSolutionNode = FALSE
55 EndGlobalSection
56 GlobalSection(ExtensibilityGlobals) = postSolution
57 SolutionGuid = {E4566A6B-47D0-4EA0-989A-D763AC39105D}
58 EndGlobalSection
59EndGlobal
diff --git a/appveyor.cmd b/appveyor.cmd
new file mode 100644
index 00000000..ff940a49
--- /dev/null
+++ b/appveyor.cmd
@@ -0,0 +1,13 @@
1@setlocal
2@pushd %~dp0
3
4nuget restore
5
6msbuild -p:Configuration=Release -t:Restore
7
8msbuild -p:Configuration=Release src\test\WixToolsetTest.NetFx\WixToolsetTest.NetFx.csproj
9
10msbuild -p:Configuration=Release -t:Pack src\wixext\WixToolset.NetFx.wixext.csproj
11
12@popd
13@endlocal \ No newline at end of file
diff --git a/appveyor.yml b/appveyor.yml
new file mode 100644
index 00000000..0c74d54b
--- /dev/null
+++ b/appveyor.yml
@@ -0,0 +1,29 @@
1image: Visual Studio 2017
2
3version: 0.0.0.{build}
4configuration: Release
5
6environment:
7 DOTNET_SKIP_FIRST_TIME_EXPERIENCE: true
8 DOTNET_CLI_TELEMETRY_OPTOUT: 1
9 NUGET_XMLDOC_MODE: skip
10
11build_script:
12 - appveyor.cmd
13
14pull_requests:
15 do_not_increment_build_number: true
16
17nuget:
18 disable_publish_on_pr: true
19
20skip_tags: true
21
22artifacts:
23- path: build\Release\**\*.nupkg
24 name: nuget
25
26notifications:
27- provider: Slack
28 incoming_webhook:
29 secure: p5xuu+4x2JHfwGDMDe5KcG1k7gZxqYc4jWVwvyNZv5cvkubPD2waJs5yXMAXZNN7Z63/3PWHb7q4KoY/99AjauYa1nZ4c5qYqRPFRBKTHfA=
diff --git a/nuget.config b/nuget.config
new file mode 100644
index 00000000..8841528e
--- /dev/null
+++ b/nuget.config
@@ -0,0 +1,16 @@
1<?xml version="1.0" encoding="utf-8"?>
2<configuration>
3 <packageSources>
4 <clear />
5 <add key="wixtoolset-data" value="https://ci.appveyor.com/nuget/wixtoolset-data" />
6 <add key="wixtoolset-extensibility" value="https://ci.appveyor.com/nuget/wixtoolset-extensibility" />
7 <add key="wixtoolset-core" value="https://ci.appveyor.com/nuget/wixtoolset-core" />
8 <add key="wixtoolset-core-native" value="https://ci.appveyor.com/nuget/wixtoolset-core-native" />
9 <add key="wixtoolset-dtf" value="https://ci.appveyor.com/nuget/wixtoolset-dtf" />
10 <add key="wixtoolset-dutil" value="https://ci.appveyor.com/nuget/wixtoolset-dutil" />
11 <add key="wixtoolset-wcautil" value="https://ci.appveyor.com/nuget/wixtoolset-wcautil" />
12 <add key="wixtoolset-util-wixext" value="https://ci.appveyor.com/nuget/wixtoolset-util-wixext" />
13 <add key="wixbuildtools" value="https://ci.appveyor.com/nuget/wixbuildtools" />
14 <add key="api.nuget.org" value="https://api.nuget.org/v3/index.json" protocolVersion="3" />
15 </packageSources>
16</configuration> \ No newline at end of file
diff --git a/src/Cpp.Build.props b/src/Cpp.Build.props
new file mode 100644
index 00000000..453aa442
--- /dev/null
+++ b/src/Cpp.Build.props
@@ -0,0 +1,101 @@
1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. -->
3
4<Project>
5 <PropertyGroup>
6 <Platform Condition=" '$(Platform)' == 'AnyCPU' ">Win32</Platform>
7 <BaseOutputPath>$(OutputPath)</BaseOutputPath>
8 <IntDir>$(BaseIntermediateOutputPath)$(Platform)\</IntDir>
9 <OutDir>$(OutputPath)$(Platform)\</OutDir>
10 </PropertyGroup>
11
12 <ItemDefinitionGroup>
13 <ClCompile>
14 <DisableSpecificWarnings>$(DisableSpecificCompilerWarnings)</DisableSpecificWarnings>
15 <WarningLevel>Level4</WarningLevel>
16 <AdditionalIncludeDirectories>$(ProjectDir)inc;$(MSBuildProjectDirectory);$(IntDir);$(SqlCESdkIncludePath);$(ProjectAdditionalIncludeDirectories);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
17 <PreprocessorDefinitions>WIN32;_WINDOWS;_WIN32_MSI=500;_WIN32_WINNT=0x0501;$(ArmPreprocessorDefinitions);$(UnicodePreprocessorDefinitions);_CRT_STDIO_LEGACY_WIDE_SPECIFIERS;_WINSOCK_DEPRECATED_NO_WARNINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
18 <PrecompiledHeader>Use</PrecompiledHeader>
19 <PrecompiledHeaderFile>precomp.h</PrecompiledHeaderFile>
20 <CallingConvention>StdCall</CallingConvention>
21 <TreatWarningAsError>true</TreatWarningAsError>
22 <ExceptionHandling>false</ExceptionHandling>
23 <AdditionalOptions>-YlprecompDefine</AdditionalOptions>
24 <AdditionalOptions Condition=" $(PlatformToolset.StartsWith('v14')) ">/Zc:threadSafeInit- %(AdditionalOptions)</AdditionalOptions>
25 <MultiProcessorCompilation Condition=" $(NUMBER_OF_PROCESSORS) &gt; 4 ">true</MultiProcessorCompilation>
26 </ClCompile>
27 <ResourceCompile>
28 <PreprocessorDefinitions>$(ArmPreprocessorDefinitions);%(PreprocessorDefinitions)</PreprocessorDefinitions>
29 <AdditionalIncludeDirectories>$(ProjectAdditionalResourceIncludeDirectories);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
30 </ResourceCompile>
31 <Lib>
32 <AdditionalLibraryDirectories>$(OutDir);$(AdditionalMultiTargetLibraryPath);$(ProjectAdditionalLibraryDirectories);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
33 </Lib>
34 <Link>
35 <SubSystem>$(ProjectSubSystem)</SubSystem>
36 <ModuleDefinitionFile>$(ProjectModuleDefinitionFile)</ModuleDefinitionFile>
37 <NoEntryPoint>$(ResourceOnlyDll)</NoEntryPoint>
38 <GenerateDebugInformation>true</GenerateDebugInformation>
39 <AdditionalDependencies>$(ProjectAdditionalLinkLibraries);advapi32.lib;comdlg32.lib;user32.lib;oleaut32.lib;gdi32.lib;shell32.lib;ole32.lib;version.lib;%(AdditionalDependencies)</AdditionalDependencies>
40 <AdditionalLibraryDirectories>$(OutDir);$(AdditionalMultiTargetLibraryPath);$(ArmLibraryDirectories);$(ProjectAdditionalLinkLibraryDirectories);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
41 <AdditionalOptions Condition=" $(PlatformToolset.StartsWith('v14')) ">/IGNORE:4099 %(AdditionalOptions)</AdditionalOptions>
42 </Link>
43 </ItemDefinitionGroup>
44
45 <ItemDefinitionGroup Condition=" '$(Platform)'=='Win32' and '$(PlatformToolset)'!='v100'">
46 <ClCompile>
47 <EnableEnhancedInstructionSet>NoExtensions</EnableEnhancedInstructionSet>
48 </ClCompile>
49 </ItemDefinitionGroup>
50 <ItemDefinitionGroup Condition=" '$(Platform)'=='arm' ">
51 <ClCompile>
52 <CallingConvention>CDecl</CallingConvention>
53 </ClCompile>
54 </ItemDefinitionGroup>
55 <ItemDefinitionGroup Condition=" '$(ConfigurationType)'=='StaticLibrary' ">
56 <ClCompile>
57 <DebugInformationFormat>OldStyle</DebugInformationFormat>
58 <OmitDefaultLibName>true</OmitDefaultLibName>
59 <IgnoreAllDefaultLibraries>true</IgnoreAllDefaultLibraries>
60 </ClCompile>
61 </ItemDefinitionGroup>
62 <ItemDefinitionGroup Condition=" '$(Configuration)'=='Debug' ">
63 <ClCompile>
64 <Optimization>Disabled</Optimization>
65 <BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
66 <PreprocessorDefinitions>_DEBUG;DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
67 <RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
68 </ClCompile>
69 </ItemDefinitionGroup>
70 <ItemDefinitionGroup Condition=" '$(Configuration)'=='Debug' and '$(CLRSupport)'=='true' ">
71 <ClCompile>
72 <BasicRuntimeChecks></BasicRuntimeChecks>
73 <RuntimeLibrary>MultiThreadedDebugDll</RuntimeLibrary>
74 </ClCompile>
75 </ItemDefinitionGroup>
76 <ItemDefinitionGroup Condition=" '$(Configuration)'=='Release' ">
77 <ClCompile>
78 <Optimization>MinSpace</Optimization>
79 <PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
80 <FunctionLevelLinking>true</FunctionLevelLinking>
81 <IntrinsicFunctions>true</IntrinsicFunctions>
82 <RuntimeLibrary>MultiThreaded</RuntimeLibrary>
83 </ClCompile>
84 <Link>
85 <EnableCOMDATFolding>true</EnableCOMDATFolding>
86 <OptimizeReferences>true</OptimizeReferences>
87 </Link>
88 </ItemDefinitionGroup>
89 <ItemDefinitionGroup Condition=" '$(Configuration)'=='Release' and '$(CLRSupport)'=='true' ">
90 <ClCompile>
91 <BasicRuntimeChecks></BasicRuntimeChecks>
92 <RuntimeLibrary>MultiThreadedDll</RuntimeLibrary>
93 </ClCompile>
94 </ItemDefinitionGroup>
95 <ItemDefinitionGroup Condition=" '$(CLRSupport)'=='true' ">
96 <Link>
97 <KeyFile>$(LinkKeyFile)</KeyFile>
98 <DelaySign>$(LinkDelaySign)</DelaySign>
99 </Link>
100 </ItemDefinitionGroup>
101</Project>
diff --git a/src/Directory.Build.props b/src/Directory.Build.props
new file mode 100644
index 00000000..63ad5d6e
--- /dev/null
+++ b/src/Directory.Build.props
@@ -0,0 +1,22 @@
1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. -->
3
4<Project>
5 <PropertyGroup>
6 <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
7 <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
8 <BaseIntermediateOutputPath>$(MSBuildThisFileDirectory)..\build\obj\$(MSBuildProjectName)\</BaseIntermediateOutputPath>
9 <OutputPath>$(MSBuildThisFileDirectory)..\build\$(Configuration)\</OutputPath>
10
11 <Authors>WiX Toolset Team</Authors>
12 <Company>WiX Toolset</Company>
13 <Copyright>Copyright (c) .NET Foundation and contributors. All rights reserved.</Copyright>
14 </PropertyGroup>
15
16 <PropertyGroup>
17 <WixToolsetRootFolder>$(MSBuildThisFileDirectory)..\..\</WixToolsetRootFolder>
18 </PropertyGroup>
19
20 <Import Project="Cpp.Build.props" Condition=" '$(MSBuildProjectExtension)'=='.vcxproj' " />
21 <Import Project="Custom.Build.props" Condition=" Exists('Custom.Build.props') " />
22</Project>
diff --git a/src/FindLocalWix.props b/src/FindLocalWix.props
new file mode 100644
index 00000000..c33939ea
--- /dev/null
+++ b/src/FindLocalWix.props
@@ -0,0 +1,10 @@
1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. -->
3
4<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
5 <PropertyGroup>
6 <WixTargetsPath Condition=" '$(Configuration)' != 'Release' And Exists('$(MSBuildThisFileDirectory)..\..\Core\README.md') ">$(MSBuildThisFileDirectory)..\..\Core\build\Debug\net461\wix.targets</WixTargetsPath>
7
8 <WixToolsetUtilWixextPath Condition=" '$(Configuration)' != 'Release' And Exists('$(MSBuildThisFileDirectory)..\..\Util.wixext\README.md') ">$(MSBuildThisFileDirectory)..\..\Util.wixext\build\Debug\netstandard2.0\WixToolset.Util.wixext.dll</WixToolsetUtilWixextPath>
9 </PropertyGroup>
10</Project>
diff --git a/src/ca/cost.h b/src/ca/cost.h
new file mode 100644
index 00000000..95368eba
--- /dev/null
+++ b/src/ca/cost.h
@@ -0,0 +1,7 @@
1#pragma once
2// Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information.
3
4
5const UINT COST_NGEN_BLOCKING = 5000;
6const UINT COST_NGEN_NONBLOCKING = 500;
7
diff --git a/src/ca/dllmain.cpp b/src/ca/dllmain.cpp
new file mode 100644
index 00000000..df53f872
--- /dev/null
+++ b/src/ca/dllmain.cpp
@@ -0,0 +1,26 @@
1// Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information.
2
3#include "precomp.h"
4
5/********************************************************************
6DllMain - standard entry point for all WiX CustomActions
7
8********************************************************************/
9extern "C" BOOL WINAPI DllMain(
10 IN HINSTANCE hInst,
11 IN ULONG ulReason,
12 IN LPVOID)
13{
14 switch(ulReason)
15 {
16 case DLL_PROCESS_ATTACH:
17 WcaGlobalInitialize(hInst);
18 break;
19
20 case DLL_PROCESS_DETACH:
21 WcaGlobalFinalize();
22 break;
23 }
24
25 return TRUE;
26}
diff --git a/src/ca/netfxca.cpp b/src/ca/netfxca.cpp
new file mode 100644
index 00000000..15802f2b
--- /dev/null
+++ b/src/ca/netfxca.cpp
@@ -0,0 +1,823 @@
1// Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information.
2
3#include "precomp.h"
4
5#define NGEN_DEBUG 0x0001
6#define NGEN_NODEP 0x0002
7#define NGEN_PROFILE 0x0004
8#define NGEN_32BIT 0x0008
9#define NGEN_64BIT 0x0010
10
11#define NGEN_TIMEOUT 60000 // 60 seconds
12
13// If you change one of these strings, be sure to change the appropriate EmptyFormattedLength variable right below
14LPCWSTR vpwzUnformattedQuotedFile = L"\"[#%s]\"";
15LPCWSTR vpwzUnformattedQuotedDirectory = L"\"[%s]\\\"";
16
17// These represent the length of the above strings in the case that the property resolves to an empty string
18const DWORD EMPTY_FORMATTED_LENGTH_QUOTED_FILE = 2;
19const DWORD EMPTY_FORMATTED_LENGTH_QUOTED_DIRECTORY = 3;
20
21LPCWSTR vcsFileId =
22 L"SELECT `File` FROM `File` WHERE `File`=?";
23enum eFileId { fiFile = 1 };
24
25LPCWSTR vcsNgenQuery =
26 L"SELECT `NetFxNativeImage`.`File_`, `NetFxNativeImage`.`NetFxNativeImage`, `NetFxNativeImage`.`Priority`, `NetFxNativeImage`.`Attributes`, `NetFxNativeImage`.`File_Application`, `NetFxNativeImage`.`Directory_ApplicationBase`, `File`.`Component_` "
27 L"FROM `NetFxNativeImage`, `File` WHERE `File`.`File`=`NetFxNativeImage`.`File_`";
28enum eNgenQuery { ngqFile = 1, ngqId, ngqPriority, ngqAttributes, ngqFileApp, ngqDirAppBase, ngqComponent };
29
30LPCWSTR vcsNgenGac =
31 L"SELECT `MsiAssembly`.`File_Application` "
32 L"FROM `File`, `MsiAssembly` WHERE `File`.`Component_`=`MsiAssembly`.`Component_` AND `File`.`File`=?";
33enum eNgenGac { nggApplication = 1 };
34
35LPCWSTR vcsNgenStrongName =
36 L"SELECT `Name`,`Value` FROM `MsiAssemblyName` WHERE `Component_`=?";
37enum eNgenStrongName { ngsnName = 1, ngsnValue };
38
39// Searches subdirectories of the given path for the highest version of ngen.exe available
40static HRESULT GetNgenVersion(
41 __in LPWSTR pwzParentPath,
42 __out LPWSTR* ppwzVersion
43 )
44{
45 Assert(pwzParentPath);
46
47 HRESULT hr = S_OK;
48 DWORD dwError = 0;
49 DWORD dwNgenFileFlags = 0;
50
51 LPWSTR pwzVersionSearch = NULL;
52 LPWSTR pwzNgen = NULL;
53 LPWSTR pwzTemp = NULL;
54 LPWSTR pwzTempVersion = NULL;
55 DWORD dwMaxMajorVersion = 0; // This stores the highest major version we've seen so far
56 DWORD dwMaxMinorVersion = 0; // This stores the minor version of the highest major version we've seen so far
57 DWORD dwMajorVersion = 0; // This stores the major version of the directory we're currently considering
58 DWORD dwMinorVersion = 0; // This stores the minor version of the directory we're currently considering
59 BOOL fFound = TRUE;
60 WIN32_FIND_DATAW wfdVersionDirectories;
61 HANDLE hFind = INVALID_HANDLE_VALUE;
62
63 hr = StrAllocFormatted(&pwzVersionSearch, L"%s*", pwzParentPath);
64 ExitOnFailure(hr, "failed to create outer directory search string from string %ls", pwzParentPath);
65 hFind = FindFirstFileW(pwzVersionSearch, &wfdVersionDirectories);
66 if (hFind == INVALID_HANDLE_VALUE)
67 {
68 ExitWithLastError(hr, "failed to call FindFirstFileW with string %ls", pwzVersionSearch);
69 }
70
71 while (fFound)
72 {
73 pwzTempVersion = (LPWSTR)&(wfdVersionDirectories.cFileName);
74
75 // Explicitly exclude v1.1.4322, which isn't backwards compatible and is not supported
76 if (wfdVersionDirectories.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
77 {
78 if (0 != lstrcmpW(L"v1.1.4322", pwzTempVersion))
79 {
80 // A potential candidate directory was found to run ngen from - let's make sure ngen actually exists here
81 hr = StrAllocFormatted(&pwzNgen, L"%s%s\\ngen.exe", pwzParentPath, pwzTempVersion);
82 ExitOnFailure(hr, "failed to create inner ngen search string with strings %ls and %ls", pwzParentPath, pwzTempVersion);
83
84 // If Ngen.exe does exist as a file here, then let's check the file version
85 if (FileExistsEx(pwzNgen, &dwNgenFileFlags) && (0 == (dwNgenFileFlags & FILE_ATTRIBUTE_DIRECTORY)))
86 {
87 hr = FileVersion(pwzNgen, &dwMajorVersion, &dwMinorVersion);
88
89 if (FAILED(hr))
90 {
91 WcaLog(LOGMSG_VERBOSE, "Failed to get version of %ls - continuing", pwzNgen);
92 }
93 else if (dwMajorVersion > dwMaxMajorVersion || (dwMajorVersion == dwMaxMajorVersion && dwMinorVersion > dwMaxMinorVersion))
94 {
95 // If the version we found is the highest we've seen so far in this search, it will be our new best-so-far candidate
96 hr = StrAllocString(ppwzVersion, pwzTempVersion, 0);
97 ExitOnFailure(hr, "failed to copy temp version string %ls to version string", pwzTempVersion);
98 // Add one for the backslash after the directory name
99 WcaLog(LOGMSG_VERBOSE, "Found highest-so-far version of ngen.exe (in directory %ls, version %u.%u.%u.%u)", *ppwzVersion, (DWORD)HIWORD(dwMajorVersion), (DWORD)LOWORD(dwMajorVersion), (DWORD)HIWORD(dwMinorVersion), (DWORD)LOWORD(dwMinorVersion));
100
101 dwMaxMajorVersion = dwMajorVersion;
102 dwMaxMinorVersion = dwMinorVersion;
103 }
104 }
105 else
106 {
107 WcaLog(LOGMSG_VERBOSE, "Ignoring %ls because it doesn't contain the file ngen.exe", pwzTempVersion);
108 }
109 }
110 else
111 {
112 WcaLog(LOGMSG_VERBOSE, "Ignoring %ls because it is from .NET Framework v1.1, which is not backwards compatible with other versions of the Framework and thus is not supported by this custom action.", pwzTempVersion);
113 }
114 }
115 else
116 {
117 WcaLog(LOGMSG_VERBOSE, "Ignoring %ls because it isn't a directory", pwzTempVersion);
118 }
119
120 fFound = FindNextFileW(hFind, &wfdVersionDirectories);
121
122 if (!fFound)
123 {
124 dwError = ::GetLastError();
125 hr = (ERROR_NO_MORE_FILES == dwError) ? ERROR_SUCCESS : HRESULT_FROM_WIN32(dwError);
126 ExitOnFailure(hr, "Failed to call FindNextFileW() with query %ls", pwzVersionSearch);
127 }
128 }
129
130 if (NULL == *ppwzVersion)
131 {
132 hr = HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND);
133 ExitOnRootFailure(hr, "Searched through all subdirectories of %ls, but failed to find any version of ngen.exe", pwzParentPath);
134 }
135 else
136 {
137 WcaLog(LOGMSG_VERBOSE, "Using highest version of ngen found, located in this subdirectory: %ls, version %u.%u.%u.%u", *ppwzVersion, (DWORD)HIWORD(dwMajorVersion), (DWORD)LOWORD(dwMajorVersion), (DWORD)HIWORD(dwMinorVersion), (DWORD)LOWORD(dwMinorVersion));
138 }
139
140LExit:
141 if (hFind != INVALID_HANDLE_VALUE)
142 {
143 if (0 == FindClose(hFind))
144 {
145 dwError = ::GetLastError();
146 hr = HRESULT_FROM_WIN32(dwError);
147 WcaLog(LOGMSG_STANDARD, "Failed to close handle created by outer FindFirstFile with error %x - continuing", hr);
148 }
149 hFind = INVALID_HANDLE_VALUE;
150 }
151
152 ReleaseStr(pwzVersionSearch);
153 ReleaseStr(pwzNgen);
154 ReleaseStr(pwzTemp);
155 // Purposely don't release pwzTempVersion, because it wasn't allocated in this function, it's just a pointer to a string inside wfdVersionDirectories
156
157 return hr;
158}
159
160// Gets the path to ngen.exe
161static HRESULT GetNgenPath(
162 __out LPWSTR* ppwzNgenPath,
163 __in BOOL f64BitFramework
164 )
165{
166 Assert(ppwzNgenPath);
167 HRESULT hr = S_OK;
168
169 LPWSTR pwzVersion = NULL;
170 LPWSTR pwzWindowsFolder = NULL;
171
172 hr = WcaGetProperty(L"WindowsFolder", &pwzWindowsFolder);
173 ExitOnFailure(hr, "failed to get WindowsFolder property");
174
175 hr = StrAllocString(ppwzNgenPath, pwzWindowsFolder, 0);
176 ExitOnFailure(hr, "failed to copy to NgenPath windows folder: %ls", pwzWindowsFolder);
177
178 if (f64BitFramework)
179 {
180 WcaLog(LOGMSG_VERBOSE, "Searching for ngen under 64-bit framework path");
181
182 hr = StrAllocConcat(ppwzNgenPath, L"Microsoft.NET\\Framework64\\", 0);
183 ExitOnFailure(hr, "failed to copy platform portion of ngen path");
184 }
185 else
186 {
187 WcaLog(LOGMSG_VERBOSE, "Searching for ngen under 32-bit framework path");
188
189 hr = StrAllocConcat(ppwzNgenPath, L"Microsoft.NET\\Framework\\", 0);
190 ExitOnFailure(hr, "failed to copy platform portion of ngen path");
191 }
192
193 // We want to run the highest version of ngen possible, because they should be backwards compatible - so let's find the most appropriate directory now
194 hr = GetNgenVersion(*ppwzNgenPath, &pwzVersion);
195 ExitOnFailure(hr, "failed to search for ngen under path %ls", *ppwzNgenPath);
196
197 hr = StrAllocConcat(ppwzNgenPath, pwzVersion, 0);
198 ExitOnFailure(hr, "failed to copy version portion of ngen path");
199
200 hr = StrAllocConcat(ppwzNgenPath, L"\\ngen.exe", 0);
201 ExitOnFailure(hr, "failed to copy \"\\ngen.exe\" portion of ngen path");
202
203LExit:
204 ReleaseStr(pwzVersion);
205 ReleaseStr(pwzWindowsFolder);
206
207 return hr;
208}
209
210
211static HRESULT GetStrongName(
212 __out LPWSTR* ppwzStrongName,
213 __in LPCWSTR pwzComponent
214 )
215{
216 Assert(ppwzStrongName);
217 HRESULT hr = S_OK;
218
219 PMSIHANDLE hView = NULL;
220 PMSIHANDLE hComponentRec = NULL;
221 PMSIHANDLE hRec = NULL;
222
223 LPWSTR pwzData = NULL;
224 LPWSTR pwzName = NULL;
225 LPWSTR pwzVersion = NULL;
226 LPWSTR pwzCulture = NULL;
227 LPWSTR pwzPublicKeyToken = NULL;
228
229 hComponentRec = ::MsiCreateRecord(1);
230 hr = WcaSetRecordString(hComponentRec, 1, pwzComponent);
231 ExitOnFailure(hr, "failed to set component value in record to: %ls", pwzComponent);
232
233 // get the name value records for this component
234 hr = WcaOpenView(vcsNgenStrongName, &hView);
235 ExitOnFailure(hr, "failed to open view on NetFxNativeImage table");
236
237 hr = WcaExecuteView(hView, hComponentRec);
238 ExitOnFailure(hr, "failed to execute strong name view");
239
240 while (S_OK == (hr = WcaFetchRecord(hView, &hRec)))
241 {
242 hr = WcaGetRecordString(hRec, ngsnName, &pwzData);
243 ExitOnFailure(hr, "failed to get MsiAssemblyName.Name for component: %ls", pwzComponent);
244
245 if (0 == lstrcmpW(L"name", pwzData))
246 {
247 hr = WcaGetRecordString(hRec, ngsnValue, &pwzName);
248 ExitOnFailure(hr, "failed to get MsiAssemblyName.Value for component: %ls Name: %ls", pwzComponent, pwzData);
249 }
250 else if (0 == lstrcmpW(L"version", pwzData))
251 {
252 hr = WcaGetRecordString(hRec, ngsnValue, &pwzVersion);
253 ExitOnFailure(hr, "failed to get MsiAssemblyName.Value for component: %ls Name: %ls", pwzComponent, pwzData);
254 }
255 else if (0 == lstrcmpW(L"culture", pwzData))
256 {
257 hr = WcaGetRecordString(hRec, ngsnValue, &pwzCulture);
258 ExitOnFailure(hr, "failed to get MsiAssemblyName.Value for component: %ls Name: %ls", pwzComponent, pwzData);
259 }
260 else if (0 == lstrcmpW(L"publicKeyToken", pwzData))
261 {
262 hr = WcaGetRecordString(hRec, ngsnValue, &pwzPublicKeyToken);
263 ExitOnFailure(hr, "failed to get MsiAssemblyName.Value for component: %ls Name: %ls", pwzComponent, pwzData);
264 }
265 }
266 if (E_NOMOREITEMS == hr)
267 hr = S_OK;
268 ExitOnFailure(hr, "failed while looping through all names and values in MsiAssemblyName table for component: %ls", pwzComponent);
269
270 hr = StrAllocFormatted(ppwzStrongName, L"\"%s, Version=%s, Culture=%s, PublicKeyToken=%s\"", pwzName, pwzVersion, pwzCulture, pwzPublicKeyToken);
271 ExitOnFailure(hr, "failed to format strong name for component: %ls", pwzComponent);
272
273LExit:
274 ReleaseStr(pwzData);
275 ReleaseStr(pwzName);
276 ReleaseStr(pwzVersion);
277 ReleaseStr(pwzCulture);
278 ReleaseStr(pwzPublicKeyToken);
279
280 return hr;
281}
282
283static HRESULT CreateInstallCommand(
284 __out LPWSTR* ppwzCommandLine,
285 __in LPCWSTR pwzNgenPath,
286 __in LPCWSTR pwzFile,
287 __in int iPriority,
288 __in int iAttributes,
289 __in LPCWSTR pwzFileApp,
290 __in LPCWSTR pwzDirAppBase
291 )
292{
293 Assert(ppwzCommandLine && pwzNgenPath && *pwzNgenPath && pwzFile && *pwzFile&& pwzFileApp && pwzDirAppBase);
294 HRESULT hr = S_OK;
295
296 LPWSTR pwzQueueString = NULL;
297
298 hr = StrAllocFormatted(ppwzCommandLine, L"%s install %s", pwzNgenPath, pwzFile);
299 ExitOnFailure(hr, "failed to assemble install command line");
300
301 if (iPriority > 0)
302 {
303 hr = StrAllocFormatted(&pwzQueueString, L" /queue:%d", iPriority);
304 ExitOnFailure(hr, "failed to format queue string");
305
306 hr = StrAllocConcat(ppwzCommandLine, pwzQueueString, 0);
307 ExitOnFailure(hr, "failed to add queue string to NGEN command line");
308 }
309
310 if (NGEN_DEBUG & iAttributes)
311 {
312 hr = StrAllocConcat(ppwzCommandLine, L" /Debug", 0);
313 ExitOnFailure(hr, "failed to add debug to NGEN command line");
314 }
315
316 if (NGEN_PROFILE & iAttributes)
317 {
318 hr = StrAllocConcat(ppwzCommandLine, L" /Profile", 0);
319 ExitOnFailure(hr, "failed to add profile to NGEN command line");
320 }
321
322 if (NGEN_NODEP & iAttributes)
323 {
324 hr = StrAllocConcat(ppwzCommandLine, L" /NoDependencies", 0);
325 ExitOnFailure(hr, "failed to add no dependencies to NGEN command line");
326 }
327
328 // If it's more than just two quotes around an empty string
329 if (EMPTY_FORMATTED_LENGTH_QUOTED_FILE < lstrlenW(pwzFileApp))
330 {
331 hr = StrAllocConcat(ppwzCommandLine, L" /ExeConfig:", 0);
332 ExitOnFailure(hr, "failed to add exe config to NGEN command line");
333
334 hr = StrAllocConcat(ppwzCommandLine, pwzFileApp, 0);
335 ExitOnFailure(hr, "failed to add file app to NGEN command line");
336 }
337
338 // If it's more than just two quotes around a backslash
339 if (EMPTY_FORMATTED_LENGTH_QUOTED_DIRECTORY < lstrlenW(pwzDirAppBase))
340 {
341 hr = StrAllocConcat(ppwzCommandLine, L" /AppBase:", 0);
342 ExitOnFailure(hr, "failed to add app base to NGEN command line");
343
344 hr = StrAllocConcat(ppwzCommandLine, pwzDirAppBase, 0);
345 ExitOnFailure(hr, "failed to add dir app base to NGEN command line");
346 }
347
348LExit:
349 return hr;
350}
351
352/******************************************************************
353 FileIdExists - checks if the file ID is found in the File table
354
355 returns S_OK if the file exists; S_FALSE if not; otherwise, error
356********************************************************************/
357static HRESULT FileIdExists(
358 __in_opt LPCWSTR wzFile
359 )
360{
361 HRESULT hr = S_OK;
362 PMSIHANDLE hView = NULL;
363 PMSIHANDLE hRec = NULL;
364
365 if (!wzFile)
366 {
367 hr = S_FALSE;
368 ExitFunction();
369 }
370
371 hRec = ::MsiCreateRecord(1);
372 hr = WcaSetRecordString(hRec, fiFile, wzFile);
373 ExitOnFailure(hr, "failed to create a record with the file: %ls", wzFile);
374
375 hr = WcaTableExists(L"File");
376 if (S_OK == hr)
377 {
378 hr = WcaOpenView(vcsFileId, &hView);
379 ExitOnFailure(hr, "failed to open view on File table");
380
381 hr = WcaExecuteView(hView, hRec);
382 ExitOnFailure(hr, "failed to execute view on File table");
383
384 // Reuse the same record; the handle will be released.
385 hr = WcaFetchSingleRecord(hView, &hRec);
386 ExitOnFailure(hr, "failed to fetch File from File table");
387 }
388
389LExit:
390
391 return hr;
392}
393
394/******************************************************************
395 SchedNetFx - entry point for NetFx Custom Action
396
397********************************************************************/
398extern "C" UINT __stdcall SchedNetFx(
399 __in MSIHANDLE hInstall
400 )
401{
402 // AssertSz(FALSE, "debug SchedNetFx");
403
404 HRESULT hr = S_OK;
405 UINT er = ERROR_SUCCESS;
406
407 LPWSTR pwzInstallCustomActionData = NULL;
408 LPWSTR pwzUninstallCustomActionData = NULL;
409 UINT uiCost = 0;
410
411 PMSIHANDLE hView = NULL;
412 PMSIHANDLE hRec = NULL;
413 PMSIHANDLE hViewGac = NULL;
414 PMSIHANDLE hRecGac = NULL;
415
416 LPWSTR pwzId = NULL;
417 LPWSTR pwzData = NULL;
418 LPWSTR pwzTemp = NULL;
419 LPWSTR pwzFile = NULL;
420 int iPriority = 0;
421 int iAssemblyCost = 0;
422 int iAttributes = 0;
423 LPWSTR pwzFileApp = NULL;
424 LPWSTR pwzDirAppBase = NULL;
425 LPWSTR pwzComponent = NULL;
426
427 INSTALLSTATE isInstalled;
428 INSTALLSTATE isAction;
429
430 LPWSTR pwz32Ngen = NULL;
431 LPWSTR pwz64Ngen = NULL;
432
433 BOOL f32NgenExeExists = FALSE;
434 BOOL f64NgenExeExists = FALSE;
435
436 BOOL fNeedInstallUpdate32 = FALSE;
437 BOOL fNeedUninstallUpdate32 = FALSE;
438 BOOL fNeedInstallUpdate64 = FALSE;
439 BOOL fNeedUninstallUpdate64 = FALSE;
440
441 // initialize
442 hr = WcaInitialize(hInstall, "SchedNetFx");
443 ExitOnFailure(hr, "failed to initialize");
444
445 hr = GetNgenPath(&pwz32Ngen, FALSE);
446 f32NgenExeExists = SUCCEEDED(hr);
447 if (HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND) == hr || HRESULT_FROM_WIN32(ERROR_PATH_NOT_FOUND) == hr)
448 {
449 hr = ERROR_SUCCESS;
450 WcaLog(LOGMSG_STANDARD, "Failed to find 32bit ngen. No actions will be scheduled to create native images for 32bit.");
451 }
452 ExitOnFailure(hr, "failed to get 32bit ngen.exe path");
453
454 hr = GetNgenPath(&pwz64Ngen, TRUE);
455 f64NgenExeExists = SUCCEEDED(hr);
456 if (HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND) == hr || HRESULT_FROM_WIN32(ERROR_PATH_NOT_FOUND) == hr)
457 {
458 hr = ERROR_SUCCESS;
459 WcaLog(LOGMSG_STANDARD, "Failed to find 64bit ngen. No actions will be scheduled to create native images for 64bit.");
460 }
461 ExitOnFailure(hr, "failed to get 64bit ngen.exe path");
462
463 // loop through all the NetFx records
464 hr = WcaOpenExecuteView(vcsNgenQuery, &hView);
465 ExitOnFailure(hr, "failed to open view on NetFxNativeImage table");
466
467 while (S_OK == (hr = WcaFetchRecord(hView, &hRec)))
468 {
469 // Get Id
470 hr = WcaGetRecordString(hRec, ngqId, &pwzId);
471 ExitOnFailure(hr, "failed to get NetFxNativeImage.NetFxNativeImage");
472
473 // Get File
474 hr = WcaGetRecordString(hRec, ngqFile, &pwzData);
475 ExitOnFailure(hr, "failed to get NetFxNativeImage.File_ for record: %ls", pwzId);
476 hr = StrAllocFormatted(&pwzTemp, vpwzUnformattedQuotedFile, pwzData);
477 ExitOnFailure(hr, "failed to format file string for file: %ls", pwzData);
478 hr = WcaGetFormattedString(pwzTemp, &pwzFile);
479 ExitOnFailure(hr, "failed to get formatted string for file: %ls", pwzData);
480
481 // Get Priority
482 hr = WcaGetRecordInteger(hRec, ngqPriority, &iPriority);
483 ExitOnFailure(hr, "failed to get NetFxNativeImage.Priority for record: %ls", pwzId);
484
485 if (0 == iPriority)
486 iAssemblyCost = COST_NGEN_BLOCKING;
487 else
488 iAssemblyCost = COST_NGEN_NONBLOCKING;
489
490 // Get Attributes
491 hr = WcaGetRecordInteger(hRec, ngqAttributes, &iAttributes);
492 ExitOnFailure(hr, "failed to get NetFxNativeImage.Attributes for record: %ls", pwzId);
493
494 // Get File_Application or leave pwzFileApp NULL.
495 hr = WcaGetRecordFormattedString(hRec, ngqFileApp, &pwzData);
496 ExitOnFailure(hr, "failed to get NetFxNativeImage.File_Application for record: %ls", pwzId);
497
498 // Check if the value resolves to a valid file ID.
499 if (S_OK == FileIdExists(pwzData))
500 {
501 // Resolve the file ID to a path.
502 hr = StrAllocFormatted(&pwzTemp, vpwzUnformattedQuotedFile, pwzData);
503 ExitOnFailure(hr, "failed to format file application string for file: %ls", pwzData);
504
505 hr = WcaGetFormattedString(pwzTemp, &pwzFileApp);
506 ExitOnFailure(hr, "failed to get formatted string for file application: %ls", pwzData);
507 }
508 else
509 {
510 // Assume record formatted to a path already.
511 hr = StrAllocString(&pwzFileApp, pwzData, 0);
512 ExitOnFailure(hr, "failed to allocate string for file path: %ls", pwzData);
513
514 hr = PathEnsureQuoted(&pwzFileApp, FALSE);
515 ExitOnFailure(hr, "failed to quote file path: %ls", pwzData);
516 }
517
518 // Get Directory_ApplicationBase or leave pwzDirAppBase NULL.
519 hr = WcaGetRecordFormattedString(hRec, ngqDirAppBase, &pwzData);
520 ExitOnFailure(hr, "failed to get NetFxNativeImage.Directory_ApplicationBase for record: %ls", pwzId);
521
522 if (WcaIsUnicodePropertySet(pwzData))
523 {
524 // Resolve the directory ID to a path.
525 hr = StrAllocFormatted(&pwzTemp, vpwzUnformattedQuotedDirectory, pwzData);
526 ExitOnFailure(hr, "failed to format directory application base string for property: %ls", pwzData);
527
528 hr = WcaGetFormattedString(pwzTemp, &pwzDirAppBase);
529 ExitOnFailure(hr, "failed to get formatted string for directory application base: %ls", pwzData);
530 }
531 else
532 {
533 // Assume record formatted to a path already.
534 hr = StrAllocString(&pwzDirAppBase, pwzData, 0);
535 ExitOnFailure(hr, "failed to allocate string for directory path: %ls", pwzData);
536
537 hr = PathEnsureQuoted(&pwzDirAppBase, TRUE);
538 ExitOnFailure(hr, "failed to quote and backslashify directory: %ls", pwzData);
539 }
540
541 // Get Component
542 hr = WcaGetRecordString(hRec, ngqComponent, &pwzComponent);
543 ExitOnFailure(hr, "failed to get NetFxNativeImage.Directory_ApplicationBase for record: %ls", pwzId);
544 er = ::MsiGetComponentStateW(hInstall, pwzComponent, &isInstalled, &isAction);
545 ExitOnWin32Error(er, hr, "failed to get install state for Component: %ls", pwzComponent);
546
547 //
548 // Figure out if it's going to be GAC'd. The possibility exists that no assemblies are going to be GAC'd
549 // so we have to check for the MsiAssembly table first.
550 //
551 if (S_OK == WcaTableExists(L"MsiAssembly"))
552 {
553 hr = WcaOpenView(vcsNgenGac, &hViewGac);
554 ExitOnFailure(hr, "failed to open view on File/MsiAssembly table");
555
556 hr = WcaExecuteView(hViewGac, hRec);
557 ExitOnFailure(hr, "failed to execute view on File/MsiAssembly table");
558
559 hr = WcaFetchSingleRecord(hViewGac, &hRecGac);
560 ExitOnFailure(hr, "failed to fetch File_Assembly from File/MsiAssembly table");
561
562 if (S_FALSE != hr)
563 {
564 hr = WcaGetRecordString(hRecGac, nggApplication, &pwzData);
565 ExitOnFailure(hr, "failed to get MsiAssembly.File_Application");
566
567 // If it's in the GAC replace the file name with the strong name
568 if (L'\0' == pwzData[0])
569 {
570 hr = GetStrongName(&pwzFile, pwzComponent);
571 ExitOnFailure(hr, "failed to get strong name for component: %ls", pwzData);
572 }
573 }
574 }
575
576 //
577 // Schedule the work
578 //
579 if (!(iAttributes & NGEN_32BIT) && !(iAttributes & NGEN_64BIT))
580 ExitOnFailure(hr = E_INVALIDARG, "Neither 32bit nor 64bit is specified for NGEN of file: %ls", pwzFile);
581
582 if (WcaIsInstalling(isInstalled, isAction) || WcaIsReInstalling(isInstalled, isAction))
583 {
584 if (iAttributes & NGEN_32BIT && f32NgenExeExists)
585 {
586 // Assemble the install command line
587 hr = CreateInstallCommand(&pwzData, pwz32Ngen, pwzFile, iPriority, iAttributes, pwzFileApp, pwzDirAppBase);
588 ExitOnFailure(hr, "failed to create install command line");
589
590 hr = WcaWriteStringToCaData(pwzData, &pwzInstallCustomActionData);
591 ExitOnFailure(hr, "failed to add install command to custom action data: %ls", pwzData);
592
593 hr = WcaWriteIntegerToCaData(iAssemblyCost, &pwzInstallCustomActionData);
594 ExitOnFailure(hr, "failed to add cost to custom action data: %ls", pwzData);
595
596 uiCost += iAssemblyCost;
597
598 fNeedInstallUpdate32 = TRUE;
599 }
600
601 if (iAttributes & NGEN_64BIT && f64NgenExeExists)
602 {
603 // Assemble the install command line
604 hr = CreateInstallCommand(&pwzData, pwz64Ngen, pwzFile, iPriority, iAttributes, pwzFileApp, pwzDirAppBase);
605 ExitOnFailure(hr, "failed to create install command line");
606
607 hr = WcaWriteStringToCaData(pwzData, &pwzInstallCustomActionData); // command
608 ExitOnFailure(hr, "failed to add install command to custom action data: %ls", pwzData);
609
610 hr = WcaWriteIntegerToCaData(iAssemblyCost, &pwzInstallCustomActionData); // cost
611 ExitOnFailure(hr, "failed to add cost to custom action data: %ls", pwzData);
612
613 uiCost += iAssemblyCost;
614
615 fNeedInstallUpdate64 = TRUE;
616 }
617 }
618 else if (WcaIsUninstalling(isInstalled, isAction))
619 {
620 if (iAttributes & NGEN_32BIT && f32NgenExeExists)
621 {
622 hr = StrAllocFormatted(&pwzData, L"%s uninstall %s", pwz32Ngen, pwzFile);
623 ExitOnFailure(hr, "failed to create update 32 command line");
624
625 hr = WcaWriteStringToCaData(pwzData, &pwzUninstallCustomActionData); // command
626 ExitOnFailure(hr, "failed to add install command to custom action data: %ls", pwzData);
627
628 hr = WcaWriteIntegerToCaData(COST_NGEN_NONBLOCKING, &pwzUninstallCustomActionData); // cost
629 ExitOnFailure(hr, "failed to add cost to custom action data: %ls", pwzData);
630
631 uiCost += COST_NGEN_NONBLOCKING;
632
633 fNeedUninstallUpdate32 = TRUE;
634 }
635
636 if (iAttributes & NGEN_64BIT && f64NgenExeExists)
637 {
638 hr = StrAllocFormatted(&pwzData, L"%s uninstall %s", pwz64Ngen, pwzFile);
639 ExitOnFailure(hr, "failed to create update 64 command line");
640
641 hr = WcaWriteStringToCaData(pwzData, &pwzUninstallCustomActionData); // command
642 ExitOnFailure(hr, "failed to add install command to custom action data: %ls", pwzData);
643
644 hr = WcaWriteIntegerToCaData(COST_NGEN_NONBLOCKING, &pwzUninstallCustomActionData); // cost
645 ExitOnFailure(hr, "failed to add cost to custom action data: %ls", pwzData);
646
647 uiCost += COST_NGEN_NONBLOCKING;
648
649 fNeedUninstallUpdate64 = TRUE;
650 }
651 }
652 }
653 if (E_NOMOREITEMS == hr)
654 hr = S_OK;
655 ExitOnFailure(hr, "failed while looping through all files to create native images for");
656
657 // If we need 32 bit install update
658 if (fNeedInstallUpdate32)
659 {
660 hr = StrAllocFormatted(&pwzData, L"%s update /queue", pwz32Ngen);
661 ExitOnFailure(hr, "failed to create install update 32 command line");
662
663 hr = WcaWriteStringToCaData(pwzData, &pwzInstallCustomActionData); // command
664 ExitOnFailure(hr, "failed to add install command to install custom action data: %ls", pwzData);
665
666 hr = WcaWriteIntegerToCaData(COST_NGEN_NONBLOCKING, &pwzInstallCustomActionData); // cost
667 ExitOnFailure(hr, "failed to add cost to install custom action data: %ls", pwzData);
668
669 uiCost += COST_NGEN_NONBLOCKING;
670 }
671
672 // If we need 32 bit uninstall update
673 if (fNeedUninstallUpdate32)
674 {
675 hr = StrAllocFormatted(&pwzData, L"%s update /queue", pwz32Ngen);
676 ExitOnFailure(hr, "failed to create uninstall update 32 command line");
677
678 hr = WcaWriteStringToCaData(pwzData, &pwzUninstallCustomActionData); // command
679 ExitOnFailure(hr, "failed to add install command to uninstall custom action data: %ls", pwzData);
680
681 hr = WcaWriteIntegerToCaData(COST_NGEN_NONBLOCKING, &pwzUninstallCustomActionData); // cost
682 ExitOnFailure(hr, "failed to add cost to uninstall custom action data: %ls", pwzData);
683
684 uiCost += COST_NGEN_NONBLOCKING;
685 }
686
687 // If we need 64 bit install update
688 if (fNeedInstallUpdate64)
689 {
690 hr = StrAllocFormatted(&pwzData, L"%s update /queue", pwz64Ngen);
691 ExitOnFailure(hr, "failed to create install update 64 command line");
692
693 hr = WcaWriteStringToCaData(pwzData, &pwzInstallCustomActionData); // command
694 ExitOnFailure(hr, "failed to add install command to install custom action data: %ls", pwzData);
695
696 hr = WcaWriteIntegerToCaData(COST_NGEN_NONBLOCKING, &pwzInstallCustomActionData); // cost
697 ExitOnFailure(hr, "failed to add cost to install custom action data: %ls", pwzData);
698
699 uiCost += COST_NGEN_NONBLOCKING;
700 }
701
702 // If we need 64 bit install update
703 if (fNeedUninstallUpdate64)
704 {
705 hr = StrAllocFormatted(&pwzData, L"%s update /queue", pwz64Ngen);
706 ExitOnFailure(hr, "failed to create uninstall update 64 command line");
707
708 hr = WcaWriteStringToCaData(pwzData, &pwzUninstallCustomActionData); // command
709 ExitOnFailure(hr, "failed to add install command to uninstall custom action data: %ls", pwzData);
710
711 hr = WcaWriteIntegerToCaData(COST_NGEN_NONBLOCKING, &pwzUninstallCustomActionData); // cost
712 ExitOnFailure(hr, "failed to add cost to uninstall custom action data: %ls", pwzData);
713
714 uiCost += COST_NGEN_NONBLOCKING;
715 }
716
717 // Add to progress bar
718 if ((pwzInstallCustomActionData && *pwzInstallCustomActionData) || (pwzUninstallCustomActionData && *pwzUninstallCustomActionData))
719 {
720 hr = WcaProgressMessage(uiCost, TRUE);
721 ExitOnFailure(hr, "failed to extend progress bar for NetFxExecuteNativeImage");
722 }
723
724 // Schedule the install custom action
725 if (pwzInstallCustomActionData && *pwzInstallCustomActionData)
726 {
727 hr = WcaSetProperty(L"NetFxExecuteNativeImageInstall", pwzInstallCustomActionData);
728 ExitOnFailure(hr, "failed to schedule NetFxExecuteNativeImageInstall action");
729
730 hr = WcaSetProperty(L"NetFxExecuteNativeImageCommitInstall", pwzInstallCustomActionData);
731 ExitOnFailure(hr, "failed to schedule NetFxExecuteNativeImageCommitInstall action");
732 }
733
734 // Schedule the uninstall custom action
735 if (pwzUninstallCustomActionData && *pwzUninstallCustomActionData)
736 {
737 hr = WcaSetProperty(L"NetFxExecuteNativeImageUninstall", pwzUninstallCustomActionData);
738 ExitOnFailure(hr, "failed to schedule NetFxExecuteNativeImageUninstall action");
739
740 hr = WcaSetProperty(L"NetFxExecuteNativeImageCommitUninstall", pwzUninstallCustomActionData);
741 ExitOnFailure(hr, "failed to schedule NetFxExecuteNativeImageCommitUninstall action");
742 }
743
744
745LExit:
746 ReleaseStr(pwzInstallCustomActionData);
747 ReleaseStr(pwzUninstallCustomActionData);
748 ReleaseStr(pwzId);
749 ReleaseStr(pwzData);
750 ReleaseStr(pwzTemp);
751 ReleaseStr(pwzFile);
752 ReleaseStr(pwzFileApp);
753 ReleaseStr(pwzDirAppBase);
754 ReleaseStr(pwzComponent);
755 ReleaseStr(pwz32Ngen);
756 ReleaseStr(pwz64Ngen);
757
758 if (FAILED(hr))
759 er = ERROR_INSTALL_FAILURE;
760 return WcaFinalize(er);
761}
762
763
764/******************************************************************
765 ExecNetFx - entry point for NetFx Custom Action
766
767*******************************************************************/
768extern "C" UINT __stdcall ExecNetFx(
769 __in MSIHANDLE hInstall
770 )
771{
772// AssertSz(FALSE, "debug ExecNetFx");
773
774 HRESULT hr = S_OK;
775 UINT er = ERROR_SUCCESS;
776
777 LPWSTR pwzCustomActionData = NULL;
778 LPWSTR pwzData = NULL;
779 LPWSTR pwz = NULL;
780 int iCost = 0;
781
782 // initialize
783 hr = WcaInitialize(hInstall, "ExecNetFx");
784 ExitOnFailure(hr, "failed to initialize");
785
786 hr = WcaGetProperty( L"CustomActionData", &pwzCustomActionData);
787 ExitOnFailure(hr, "failed to get CustomActionData");
788
789 WcaLog(LOGMSG_TRACEONLY, "CustomActionData: %ls", pwzCustomActionData);
790
791 pwz = pwzCustomActionData;
792
793 // loop through all the passed in data
794 while (pwz && *pwz)
795 {
796 hr = WcaReadStringFromCaData(&pwz, &pwzData);
797 ExitOnFailure(hr, "failed to read command line from custom action data");
798
799 hr = WcaReadIntegerFromCaData(&pwz, &iCost);
800 ExitOnFailure(hr, "failed to read cost from custom action data");
801
802 hr = QuietExec(pwzData, NGEN_TIMEOUT, TRUE, TRUE);
803 // If we fail here it isn't critical - keep looping through to try to act on the other assemblies on our list
804 if (FAILED(hr))
805 {
806 WcaLog(LOGMSG_STANDARD, "failed to execute Ngen command (with error 0x%x): %ls, continuing anyway", hr, pwzData);
807 hr = S_OK;
808 }
809
810 // Tick the progress bar along for this assembly
811 hr = WcaProgressMessage(iCost, FALSE);
812 ExitOnFailure(hr, "failed to tick progress bar for command line: %ls", pwzData);
813 }
814
815LExit:
816 ReleaseStr(pwzCustomActionData);
817 ReleaseStr(pwzData);
818
819 if (FAILED(hr))
820 er = ERROR_INSTALL_FAILURE;
821 return WcaFinalize(er);
822}
823
diff --git a/src/ca/netfxca.def b/src/ca/netfxca.def
new file mode 100644
index 00000000..c1d01f5f
--- /dev/null
+++ b/src/ca/netfxca.def
@@ -0,0 +1,8 @@
1; Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information.
2
3
4LIBRARY "netfxca"
5
6EXPORTS
7 SchedNetFx
8 ExecNetFx
diff --git a/src/ca/netfxca.vcxproj b/src/ca/netfxca.vcxproj
new file mode 100644
index 00000000..98b7352b
--- /dev/null
+++ b/src/ca/netfxca.vcxproj
@@ -0,0 +1,70 @@
1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. -->
3
4<Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
5 <Import Project="..\..\packages\WixToolset.DUtil.4.0.6\build\WixToolset.DUtil.props" Condition="Exists('..\..\packages\WixToolset.DUtil.4.0.6\build\WixToolset.DUtil.props')" />
6 <Import Project="..\..\packages\WixToolset.WcaUtil.4.0.2\build\WixToolset.WcaUtil.props" Condition="Exists('..\..\packages\WixToolset.WcaUtil.4.0.2\build\WixToolset.WcaUtil.props')" />
7
8 <ItemGroup Label="ProjectConfigurations">
9 <ProjectConfiguration Include="Debug|Win32">
10 <Configuration>Debug</Configuration>
11 <Platform>Win32</Platform>
12 </ProjectConfiguration>
13 <ProjectConfiguration Include="Release|Win32">
14 <Configuration>Release</Configuration>
15 <Platform>Win32</Platform>
16 </ProjectConfiguration>
17 </ItemGroup>
18
19 <PropertyGroup Label="Globals">
20 <ProjectGuid>{F72D34CA-48DA-4DFD-91A9-A0C78BEF6981}</ProjectGuid>
21 <ConfigurationType>DynamicLibrary</ConfigurationType>
22 <TargetName>netfxca</TargetName>
23 <PlatformToolset>v141</PlatformToolset>
24 <CharacterSet>Unicode</CharacterSet>
25 <ProjectModuleDefinitionFile>netfxca.def</ProjectModuleDefinitionFile>
26 <Description>WiX Toolset .NET Framework CustomAction</Description>
27 </PropertyGroup>
28
29 <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
30 <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
31
32 <ImportGroup Label="ExtensionSettings">
33 </ImportGroup>
34
35 <ImportGroup Label="Shared">
36 <Import Project="..\..\packages\Microsoft.VisualStudio.Setup.Configuration.Native.1.14.114\build\native\Microsoft.VisualStudio.Setup.Configuration.Native.targets" Condition="Exists('..\..\packages\Microsoft.VisualStudio.Setup.Configuration.Native.1.14.114\build\native\Microsoft.VisualStudio.Setup.Configuration.Native.targets')" />
37 </ImportGroup>
38
39 <PropertyGroup>
40 <ProjectAdditionalLinkLibraries>msi.lib</ProjectAdditionalLinkLibraries>
41 </PropertyGroup>
42
43 <ItemGroup>
44 <ClCompile Include="dllmain.cpp">
45 <PrecompiledHeader>Create</PrecompiledHeader>
46 </ClCompile>
47 <ClCompile Include="netfxca.cpp" />
48 </ItemGroup>
49
50 <ItemGroup>
51 <ClInclude Include="cost.h" />
52 <ClInclude Include="precomp.h" />
53 </ItemGroup>
54
55 <ItemGroup>
56 <None Include="packages.config" />
57 <None Include="netfxca.def" />
58 </ItemGroup>
59
60 <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
61
62 <Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
63 <PropertyGroup>
64 <ErrorText>This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
65 </PropertyGroup>
66 <Error Condition="!Exists('..\..\packages\Microsoft.VisualStudio.Setup.Configuration.Native.1.14.114\build\native\Microsoft.VisualStudio.Setup.Configuration.Native.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\..\packages\Microsoft.VisualStudio.Setup.Configuration.Native.1.14.114\build\native\Microsoft.VisualStudio.Setup.Configuration.Native.targets'))" />
67 <Error Condition="!Exists('..\..\packages\WixToolset.DUtil.4.0.6\build\WixToolset.DUtil.props')" Text="$([System.String]::Format('$(ErrorText)', '..\..\packages\WixToolset.DUtil.4.0.6\build\WixToolset.DUtil.props'))" />
68 <Error Condition="!Exists('..\..\packages\WixToolset.WcaUtil.4.0.2\build\WixToolset.WcaUtil.props')" Text="$([System.String]::Format('$(ErrorText)', '..\..\packages\WixToolset.WcaUtil.4.0.2\build\WixToolset.WcaUtil.props'))" />
69 </Target>
70</Project> \ No newline at end of file
diff --git a/src/ca/packages.config b/src/ca/packages.config
new file mode 100644
index 00000000..b74ff5d0
--- /dev/null
+++ b/src/ca/packages.config
@@ -0,0 +1,6 @@
1<?xml version="1.0" encoding="utf-8"?>
2<packages>
3 <package id="Microsoft.VisualStudio.Setup.Configuration.Native" version="1.14.114" targetFramework="native" developmentDependency="true" />
4 <package id="WixToolset.DUtil" version="4.0.6" targetFramework="native" />
5 <package id="WixToolset.WcaUtil" version="4.0.2" targetFramework="native" />
6</packages> \ No newline at end of file
diff --git a/src/ca/precomp.h b/src/ca/precomp.h
new file mode 100644
index 00000000..5caedb16
--- /dev/null
+++ b/src/ca/precomp.h
@@ -0,0 +1,13 @@
1#pragma once
2// Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information.
3
4
5#include <windows.h>
6#include <msiquery.h>
7
8#include "wcautil.h"
9#include "fileutil.h"
10#include "strutil.h"
11#include "pathutil.h"
12
13#include "cost.h"
diff --git a/src/test/WixToolsetTest.Netfx/NetfxExtensionFixture.cs b/src/test/WixToolsetTest.Netfx/NetfxExtensionFixture.cs
new file mode 100644
index 00000000..a9428d7c
--- /dev/null
+++ b/src/test/WixToolsetTest.Netfx/NetfxExtensionFixture.cs
@@ -0,0 +1,33 @@
1// Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information.
2
3namespace WixToolsetTest.Netfx
4{
5 using System.Linq;
6 using WixBuildTools.TestSupport;
7 using WixToolset.Core.TestPackage;
8 using WixToolset.Netfx;
9 using Xunit;
10
11 public class NetfxExtensionFixture
12 {
13 [Fact]
14 public void CanBuildUsingNativeImage()
15 {
16 var folder = TestData.Get(@"TestData\UsingNativeImage");
17 var build = new Builder(folder, typeof(NetfxExtensionFactory), new[] { folder });
18
19 var results = build.BuildAndQuery(Build, "NetFxNativeImage");
20 Assert.Equal(new[]
21 {
22 "NetFxNativeImage:ExampleNgen\tfil6349_KNDJhqShNzVdHX3ihhvA6Y\t3\t8\t\t",
23 }, results.OrderBy(s => s).ToArray());
24 }
25
26 private static void Build(string[] args)
27 {
28 var result = WixRunner.Execute(args, out var messages);
29 Assert.Equal(0, result);
30 Assert.Empty(messages);
31 }
32 }
33}
diff --git a/src/test/WixToolsetTest.Netfx/TestData/UsingNativeImage/Package.en-us.wxl b/src/test/WixToolsetTest.Netfx/TestData/UsingNativeImage/Package.en-us.wxl
new file mode 100644
index 00000000..38c12ac1
--- /dev/null
+++ b/src/test/WixToolsetTest.Netfx/TestData/UsingNativeImage/Package.en-us.wxl
@@ -0,0 +1,11 @@
1<?xml version="1.0" encoding="utf-8"?>
2
3<!--
4This file contains the declaration of all the localizable strings.
5-->
6<WixLocalization xmlns="http://wixtoolset.org/schemas/v4/wxl" Culture="en-US">
7
8 <String Id="DowngradeError">A newer version of [ProductName] is already installed.</String>
9 <String Id="FeatureTitle">MsiPackage</String>
10
11</WixLocalization>
diff --git a/src/test/WixToolsetTest.Netfx/TestData/UsingNativeImage/Package.wxs b/src/test/WixToolsetTest.Netfx/TestData/UsingNativeImage/Package.wxs
new file mode 100644
index 00000000..68ff98fd
--- /dev/null
+++ b/src/test/WixToolsetTest.Netfx/TestData/UsingNativeImage/Package.wxs
@@ -0,0 +1,22 @@
1<?xml version="1.0" encoding="utf-8"?>
2<Wix xmlns="http://wixtoolset.org/schemas/v4/wxs">
3 <Product Id="*" Name="MsiPackage" Language="1033" Version="1.0.0.0" Manufacturer="Example Corporation" UpgradeCode="047730a5-30fe-4a62-a520-da9381b8226a">
4 <Package InstallerVersion="200" Compressed="no" InstallScope="perMachine" />
5
6 <MajorUpgrade DowngradeErrorMessage="!(loc.DowngradeError)" />
7 <MediaTemplate />
8
9 <Feature Id="ProductFeature" Title="!(loc.FeatureTitle)">
10 <ComponentGroupRef Id="ProductComponents" />
11 </Feature>
12
13 </Product>
14
15 <Fragment>
16 <Directory Id="TARGETDIR" Name="SourceDir">
17 <Directory Id="ProgramFilesFolder">
18 <Directory Id="INSTALLFOLDER" Name="MsiPackage" />
19 </Directory>
20 </Directory>
21 </Fragment>
22</Wix>
diff --git a/src/test/WixToolsetTest.Netfx/TestData/UsingNativeImage/PackageComponents.wxs b/src/test/WixToolsetTest.Netfx/TestData/UsingNativeImage/PackageComponents.wxs
new file mode 100644
index 00000000..21c92f26
--- /dev/null
+++ b/src/test/WixToolsetTest.Netfx/TestData/UsingNativeImage/PackageComponents.wxs
@@ -0,0 +1,13 @@
1<?xml version="1.0" encoding="utf-8"?>
2<Wix xmlns="http://wixtoolset.org/schemas/v4/wxs"
3 xmlns:netfx="http://wixtoolset.org/schemas/v4/wxs/netfx">
4 <Fragment>
5 <ComponentGroup Id="ProductComponents" Directory="INSTALLFOLDER">
6 <Component>
7 <File Name="fake.ddl" Source="example.txt">
8 <netfx:NativeImage Id="ExampleNgen" />
9 </File>
10 </Component>
11 </ComponentGroup>
12 </Fragment>
13</Wix>
diff --git a/src/test/WixToolsetTest.Netfx/TestData/UsingNativeImage/example.txt b/src/test/WixToolsetTest.Netfx/TestData/UsingNativeImage/example.txt
new file mode 100644
index 00000000..1b4ffe8a
--- /dev/null
+++ b/src/test/WixToolsetTest.Netfx/TestData/UsingNativeImage/example.txt
@@ -0,0 +1 @@
This is example.txt. \ No newline at end of file
diff --git a/src/test/WixToolsetTest.Netfx/WixToolsetTest.Netfx.csproj b/src/test/WixToolsetTest.Netfx/WixToolsetTest.Netfx.csproj
new file mode 100644
index 00000000..45429574
--- /dev/null
+++ b/src/test/WixToolsetTest.Netfx/WixToolsetTest.Netfx.csproj
@@ -0,0 +1,40 @@
1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. -->
3
4<Project Sdk="Microsoft.NET.Sdk">
5 <PropertyGroup>
6 <TargetFramework>netcoreapp2.0</TargetFramework>
7 <IsPackable>false</IsPackable>
8 </PropertyGroup>
9
10 <PropertyGroup>
11 <NoWarn>NU1701</NoWarn>
12 </PropertyGroup>
13
14 <ItemGroup>
15 <Content Include="TestData\UsingNativeImage\example.txt" CopyToOutputDirectory="PreserveNewest" />
16 <Content Include="TestData\UsingNativeImage\Package.en-us.wxl" CopyToOutputDirectory="PreserveNewest" />
17 <Content Include="TestData\UsingNativeImage\Package.wxs" CopyToOutputDirectory="PreserveNewest" />
18 <Content Include="TestData\UsingNativeImage\PackageComponents.wxs" CopyToOutputDirectory="PreserveNewest" />
19 </ItemGroup>
20
21 <ItemGroup>
22 <ProjectReference Include="..\..\wixext\WixToolset.Netfx.wixext.csproj" />
23 </ItemGroup>
24
25 <ItemGroup>
26 <ProjectReference Include="$(WixToolsetRootFolder)\Core\src\WixToolset.Core.TestPackage\WixToolset.Core.TestPackage.csproj" Condition=" '$(Configuration)' == 'Debug' And Exists('$(WixToolsetRootFolder)\Core\README.md') " />
27 <ProjectReference Include="$(WixToolsetRootFolder)\Core\src\wix\wix.csproj" Condition=" '$(Configuration)' == 'Debug' And Exists('$(WixToolsetRootFolder)\Core\README.md') " />
28 <PackageReference Include="WixToolset.Core.TestPackage" Version="4.0.*" Condition=" '$(Configuration)' == 'Release' Or !Exists('$(WixToolsetRootFolder)\Core\README.md') " PrivateAssets="all" />
29 </ItemGroup>
30
31 <ItemGroup>
32 <PackageReference Include="WixBuildTools.TestSupport" Version="4.0.*" />
33 </ItemGroup>
34
35 <ItemGroup>
36 <PackageReference Include="Microsoft.NET.Test.Sdk" Version="15.3.0-preview-20170628-02" />
37 <PackageReference Include="xunit" Version="2.2.0" />
38 <PackageReference Include="xunit.runner.visualstudio" Version="2.2.0" />
39 </ItemGroup>
40</Project>
diff --git a/src/wixext/NetFxCompiler.cs b/src/wixext/NetFxCompiler.cs
new file mode 100644
index 00000000..55db4297
--- /dev/null
+++ b/src/wixext/NetFxCompiler.cs
@@ -0,0 +1,159 @@
1// Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information.
2
3namespace WixToolset.Netfx
4{
5 using System;
6 using System.Collections.Generic;
7 using System.Xml.Linq;
8 using WixToolset.Data;
9 using WixToolset.Extensibility;
10
11 /// <summary>
12 /// The compiler for the WiX Toolset .NET Framework Extension.
13 /// </summary>
14 public sealed class NetfxCompiler : BaseCompilerExtension
15 {
16 public override XNamespace Namespace => "http://wixtoolset.org/schemas/v4/wxs/netfx";
17
18 /// <summary>
19 /// Processes an element for the Compiler.
20 /// </summary>
21 /// <param name="parentElement">Parent element of element to process.</param>
22 /// <param name="element">Element to process.</param>
23 /// <param name="contextValues">Extra information about the context in which this element is being parsed.</param>
24 public override void ParseElement(Intermediate intermediate, IntermediateSection section, XElement parentElement, XElement element, IDictionary<string, string> context)
25 {
26 switch (parentElement.Name.LocalName)
27 {
28 case "File":
29 string fileId = context["FileId"];
30
31 switch (element.Name.LocalName)
32 {
33 case "NativeImage":
34 this.ParseNativeImageElement(intermediate, section, element, fileId);
35 break;
36 default:
37 this.ParseHelper.UnexpectedElement(parentElement, element);
38 break;
39 }
40 break;
41 default:
42 this.ParseHelper.UnexpectedElement(parentElement, element);
43 break;
44 }
45 }
46
47 /// <summary>
48 /// Parses a NativeImage element.
49 /// </summary>
50 /// <param name="element">The element to parse.</param>
51 /// <param name="fileId">The file identifier of the parent element.</param>
52 private void ParseNativeImageElement(Intermediate intermediate, IntermediateSection section, XElement element, string fileId)
53 {
54 SourceLineNumber sourceLineNumbers = this.ParseHelper.GetSourceLineNumbers(element);
55 Identifier id = null;
56 string appBaseDirectory = null;
57 string assemblyApplication = null;
58 int attributes = 0x8; // 32bit is on by default
59 int priority = 3;
60
61 foreach (XAttribute attrib in element.Attributes())
62 {
63 if (String.IsNullOrEmpty(attrib.Name.NamespaceName) || this.Namespace == attrib.Name.Namespace)
64 {
65 switch (attrib.Name.LocalName)
66 {
67 case "Id":
68 id = this.ParseHelper.GetAttributeIdentifier(sourceLineNumbers, attrib);
69 break;
70 case "AppBaseDirectory":
71 appBaseDirectory = this.ParseHelper.GetAttributeValue(sourceLineNumbers, attrib);
72
73 // See if a formatted value is specified.
74 if (-1 == appBaseDirectory.IndexOf("[", StringComparison.Ordinal))
75 {
76 this.ParseHelper.CreateSimpleReference(section, sourceLineNumbers, "Directory", appBaseDirectory);
77 }
78 break;
79 case "AssemblyApplication":
80 assemblyApplication = this.ParseHelper.GetAttributeValue(sourceLineNumbers, attrib);
81
82 // See if a formatted value is specified.
83 if (-1 == assemblyApplication.IndexOf("[", StringComparison.Ordinal))
84 {
85 this.ParseHelper.CreateSimpleReference(section, sourceLineNumbers, "File", assemblyApplication);
86 }
87 break;
88 case "Debug":
89 if (YesNoType.Yes == this.ParseHelper.GetAttributeYesNoValue(sourceLineNumbers, attrib))
90 {
91 attributes |= 0x1;
92 }
93 break;
94 case "Dependencies":
95 if (YesNoType.No == this.ParseHelper.GetAttributeYesNoValue(sourceLineNumbers, attrib))
96 {
97 attributes |= 0x2;
98 }
99 break;
100 case "Platform":
101 string platformValue = this.ParseHelper.GetAttributeValue(sourceLineNumbers, attrib);
102 if (0 < platformValue.Length)
103 {
104 switch (platformValue)
105 {
106 case "32bit":
107 // 0x8 is already on by default
108 break;
109 case "64bit":
110 attributes &= ~0x8;
111 attributes |= 0x10;
112 break;
113 case "all":
114 attributes |= 0x10;
115 break;
116 }
117 }
118 break;
119 case "Priority":
120 priority = this.ParseHelper.GetAttributeIntegerValue(sourceLineNumbers, attrib, 0, 3);
121 break;
122 case "Profile":
123 if (YesNoType.Yes == this.ParseHelper.GetAttributeYesNoValue(sourceLineNumbers, attrib))
124 {
125 attributes |= 0x4;
126 }
127 break;
128 default:
129 this.ParseHelper.UnexpectedAttribute(element, attrib);
130 break;
131 }
132 }
133 else
134 {
135 this.ParseHelper.ParseExtensionAttribute(this.Context.Extensions, intermediate, section, element, attrib);
136 }
137 }
138
139 if (null == id)
140 {
141 this.Messaging.Write(ErrorMessages.ExpectedAttribute(sourceLineNumbers, element.Name.LocalName, "Id"));
142 }
143
144 this.ParseHelper.ParseForExtensionElements(this.Context.Extensions, intermediate, section, element);
145
146 this.ParseHelper.CreateSimpleReference(section, sourceLineNumbers, "CustomAction", "NetFxScheduleNativeImage");
147
148 if (!this.Messaging.EncounteredError)
149 {
150 var row = this.ParseHelper.CreateRow(section, sourceLineNumbers, "NetFxNativeImage", id);
151 row.Set(1, fileId);
152 row.Set(2, priority);
153 row.Set(3, attributes);
154 row.Set(4, assemblyApplication);
155 row.Set(5, appBaseDirectory);
156 }
157 }
158 }
159}
diff --git a/src/wixext/NetFxDecompiler.cs b/src/wixext/NetFxDecompiler.cs
new file mode 100644
index 00000000..e30905d1
--- /dev/null
+++ b/src/wixext/NetFxDecompiler.cs
@@ -0,0 +1,139 @@
1// Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information.
2
3namespace WixToolset.Extensions
4{
5#if TODO_CONSIDER_DECOMPILER
6 using System;
7 using System.Collections;
8 using System.Diagnostics;
9 using System.Globalization;
10 using WixToolset.Data;
11 using WixToolset.Extensibility;
12 using NetFx = WixToolset.Extensions.Serialize.NetFx;
13 using Wix = WixToolset.Data.Serialize;
14
15 /// <summary>
16 /// The decompiler for the WiX Toolset .NET Framework Extension.
17 /// </summary>
18 public sealed class NetFxDecompiler : DecompilerExtension
19 {
20 /// <summary>
21 /// Creates a decompiler for NetFx Extension.
22 /// </summary>
23 public NetFxDecompiler()
24 {
25 this.TableDefinitions = NetFxExtensionData.GetExtensionTableDefinitions();
26 }
27
28 /// <summary>
29 /// Get the extensions library to be removed.
30 /// </summary>
31 /// <param name="tableDefinitions">Table definitions for library.</param>
32 /// <returns>Library to remove from decompiled output.</returns>
33 public override Library GetLibraryToRemove(TableDefinitionCollection tableDefinitions)
34 {
35 return NetFxExtensionData.GetExtensionLibrary(tableDefinitions);
36 }
37
38 /// <summary>
39 /// Decompiles an extension table.
40 /// </summary>
41 /// <param name="table">The table to decompile.</param>
42 public override void DecompileTable(Table table)
43 {
44 switch (table.Name)
45 {
46 case "NetFxNativeImage":
47 this.DecompileNetFxNativeImageTable(table);
48 break;
49 default:
50 base.DecompileTable(table);
51 break;
52 }
53 }
54
55 /// <summary>
56 /// Decompile the NetFxNativeImage table.
57 /// </summary>
58 /// <param name="table">The table to decompile.</param>
59 private void DecompileNetFxNativeImageTable(Table table)
60 {
61 foreach (Row row in table.Rows)
62 {
63 NetFx.NativeImage nativeImage = new NetFx.NativeImage();
64
65 nativeImage.Id = (string)row[0];
66
67 switch ((int)row[2])
68 {
69 case 0:
70 nativeImage.Priority = NetFx.NativeImage.PriorityType.Item0;
71 break;
72 case 1:
73 nativeImage.Priority = NetFx.NativeImage.PriorityType.Item1;
74 break;
75 case 2:
76 nativeImage.Priority = NetFx.NativeImage.PriorityType.Item2;
77 break;
78 case 3:
79 nativeImage.Priority = NetFx.NativeImage.PriorityType.Item3;
80 break;
81 }
82
83 if (null != row[3])
84 {
85 int attributes = (int)row[3];
86
87 if (0x1 == (attributes & 0x1))
88 {
89 nativeImage.Debug = NetFx.YesNoType.yes;
90 }
91
92 if (0x2 == (attributes & 0x2))
93 {
94 nativeImage.Dependencies = NetFx.YesNoType.no;
95 }
96
97 if (0x4 == (attributes & 0x4))
98 {
99 nativeImage.Profile = NetFx.YesNoType.yes;
100 }
101
102 if (0x8 == (attributes & 0x8) && 0x10 == (attributes & 0x10))
103 {
104 nativeImage.Platform = NetFx.NativeImage.PlatformType.all;
105 }
106 else if (0x8 == (attributes & 0x8))
107 {
108 nativeImage.Platform = NetFx.NativeImage.PlatformType.Item32bit;
109 }
110 else if (0x10 == (attributes & 0x10))
111 {
112 nativeImage.Platform = NetFx.NativeImage.PlatformType.Item64bit;
113 }
114 }
115
116 if (null != row[4])
117 {
118 nativeImage.AssemblyApplication = (string)row[4];
119 }
120
121 if (null != row[5])
122 {
123 nativeImage.AppBaseDirectory = (string)row[5];
124 }
125
126 Wix.File file = (Wix.File)this.Core.GetIndexedElement("File", (string)row[1]);
127 if (null != file)
128 {
129 file.AddChild(nativeImage);
130 }
131 else
132 {
133 this.Core.OnMessage(WixWarnings.ExpectedForeignRow(row.SourceLineNumbers, table.Name, row.GetPrimaryKey(DecompilerConstants.PrimaryKeyDelimiter), "File_", (string)row[1], "File"));
134 }
135 }
136 }
137 }
138#endif
139}
diff --git a/src/wixext/NetFxExtensionData.cs b/src/wixext/NetFxExtensionData.cs
new file mode 100644
index 00000000..b68741fd
--- /dev/null
+++ b/src/wixext/NetFxExtensionData.cs
@@ -0,0 +1,25 @@
1// Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information.
2
3namespace WixToolset.Netfx
4{
5 using WixToolset.Data;
6 using WixToolset.Extensibility;
7 using WixToolset.Netfx.Tuples;
8
9 /// <summary>
10 /// The WiX Toolset .NET Framework Extension.
11 /// </summary>
12 public sealed class NetfxExtensionData : BaseExtensionData
13 {
14 public override bool TryGetTupleDefinitionByName(string name, out IntermediateTupleDefinition tupleDefinition)
15 {
16 tupleDefinition = (name == NetfxTupleDefinitionNames.NetFxNativeImage) ? NetfxTupleDefinitions.NetFxNativeImage : null;
17 return tupleDefinition != null;
18 }
19
20 public override Intermediate GetLibrary(ITupleDefinitionCreator tupleDefinitions)
21 {
22 return Intermediate.Load(typeof(NetfxExtensionData).Assembly, "WixToolset.Netfx.netfx.wixlib", tupleDefinitions);
23 }
24 }
25}
diff --git a/src/wixext/NetfxExtensionFactory.cs b/src/wixext/NetfxExtensionFactory.cs
new file mode 100644
index 00000000..756d1b2a
--- /dev/null
+++ b/src/wixext/NetfxExtensionFactory.cs
@@ -0,0 +1,18 @@
1// Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information.
2
3namespace WixToolset.Netfx
4{
5 using System;
6 using System.Collections.Generic;
7 using WixToolset.Extensibility;
8
9 public class NetfxExtensionFactory : BaseExtensionFactory
10 {
11 protected override IEnumerable<Type> ExtensionTypes => new[]
12 {
13 typeof(NetfxCompiler),
14 typeof(NetfxExtensionData),
15 typeof(NetfxWindowsInstallerBackendExtension),
16 };
17 }
18}
diff --git a/src/wixext/NetfxWindowsInstallerBackendExtension.cs b/src/wixext/NetfxWindowsInstallerBackendExtension.cs
new file mode 100644
index 00000000..50266ef4
--- /dev/null
+++ b/src/wixext/NetfxWindowsInstallerBackendExtension.cs
@@ -0,0 +1,27 @@
1// Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information.
2
3namespace WixToolset.Netfx
4{
5 using WixToolset.Data.WindowsInstaller;
6 using WixToolset.Extensibility;
7
8 public class NetfxWindowsInstallerBackendExtension : BaseWindowsInstallerBackendExtension
9 {
10 private static readonly TableDefinition[] Tables = new[] {
11 new TableDefinition(
12 "NetFxNativeImage",
13 new[]
14 {
15 new ColumnDefinition("NetFxNativeImage", ColumnType.String, 72, true, false, ColumnCategory.Identifier, description: "The primary key, a non-localized token."),
16 new ColumnDefinition("File_", ColumnType.String, 0, false, false, ColumnCategory.Identifier, keyTable:"File", keyColumn: 1, description: "The assembly for which a native image will be generated."),
17 new ColumnDefinition("Priority", ColumnType.Number, 2, false, false, ColumnCategory.Integer, maxValue: 3, description: "The priority for generating this native image: 0 is syncronous, 1-3 represent various levels of queued generation."),
18 new ColumnDefinition("Attributes", ColumnType.Number, 4, false, false, ColumnCategory.Integer, maxValue: 2147483647, description: "Integer containing bit flags representing native image attributes."),
19 new ColumnDefinition("File_Application", ColumnType.String, 72, false, true, ColumnCategory.Formatted, description: "The application which loads this assembly."),
20 new ColumnDefinition("Directory_ApplicationBase", ColumnType.String, 72, false, true, ColumnCategory.Formatted, description: "The directory containing the application which loads this assembly."),
21 }
22 ),
23 };
24
25 protected override TableDefinition[] TableDefinitionsForTuples => Tables;
26 }
27}
diff --git a/src/wixext/Tuples/NetFxNativeImageTuple.cs b/src/wixext/Tuples/NetFxNativeImageTuple.cs
new file mode 100644
index 00000000..af507137
--- /dev/null
+++ b/src/wixext/Tuples/NetFxNativeImageTuple.cs
@@ -0,0 +1,65 @@
1// Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information.
2
3namespace WixToolset.Netfx.Tuples
4{
5 using WixToolset.Data;
6
7 public enum NetFxNativeImageTupleFields
8 {
9 NetFxNativeImage,
10 File_,
11 Priority,
12 Attributes,
13 File_Application,
14 Directory_ApplicationBase,
15 }
16
17 public class NetFxNativeImageTuple : IntermediateTuple
18 {
19 public NetFxNativeImageTuple() : base(NetfxTupleDefinitions.NetFxNativeImage, null, null)
20 {
21 }
22
23 public NetFxNativeImageTuple(SourceLineNumber sourceLineNumber, Identifier id = null) : base(NetfxTupleDefinitions.NetFxNativeImage, sourceLineNumber, id)
24 {
25 }
26
27 public IntermediateField this[NetFxNativeImageTupleFields index] => this.Fields[(int)index];
28
29 public string NetFxNativeImage
30 {
31 get => this.Fields[(int)NetFxNativeImageTupleFields.NetFxNativeImage].AsString();
32 set => this.Set((int)NetFxNativeImageTupleFields.NetFxNativeImage, value);
33 }
34
35 public string File_
36 {
37 get => this.Fields[(int)NetFxNativeImageTupleFields.File_].AsString();
38 set => this.Set((int)NetFxNativeImageTupleFields.File_, value);
39 }
40
41 public int Priority
42 {
43 get => this.Fields[(int)NetFxNativeImageTupleFields.Priority].AsNumber();
44 set => this.Set((int)NetFxNativeImageTupleFields.Priority, value);
45 }
46
47 public int Attributes
48 {
49 get => this.Fields[(int)NetFxNativeImageTupleFields.Attributes].AsNumber();
50 set => this.Set((int)NetFxNativeImageTupleFields.Attributes, value);
51 }
52
53 public string File_Application
54 {
55 get => this.Fields[(int)NetFxNativeImageTupleFields.File_Application].AsString();
56 set => this.Set((int)NetFxNativeImageTupleFields.File_Application, value);
57 }
58
59 public string Directory_ApplicationBase
60 {
61 get => this.Fields[(int)NetFxNativeImageTupleFields.Directory_ApplicationBase].AsString();
62 set => this.Set((int)NetFxNativeImageTupleFields.Directory_ApplicationBase, value);
63 }
64 }
65} \ No newline at end of file
diff --git a/src/wixext/Tuples/NetfxTupleDefinitions.cs b/src/wixext/Tuples/NetfxTupleDefinitions.cs
new file mode 100644
index 00000000..aa584b38
--- /dev/null
+++ b/src/wixext/Tuples/NetfxTupleDefinitions.cs
@@ -0,0 +1,27 @@
1// Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information.
2
3namespace WixToolset.Netfx.Tuples
4{
5 using WixToolset.Data;
6
7 public static class NetfxTupleDefinitionNames
8 {
9 public static string NetFxNativeImage { get; } = "NetFxNativeImage";
10 }
11
12 public static class NetfxTupleDefinitions
13 {
14 public static readonly IntermediateTupleDefinition NetFxNativeImage = new IntermediateTupleDefinition(
15 NetfxTupleDefinitionNames.NetFxNativeImage,
16 new[]
17 {
18 new IntermediateFieldDefinition(nameof(NetFxNativeImageTupleFields.NetFxNativeImage), IntermediateFieldType.String),
19 new IntermediateFieldDefinition(nameof(NetFxNativeImageTupleFields.File_), IntermediateFieldType.String),
20 new IntermediateFieldDefinition(nameof(NetFxNativeImageTupleFields.Priority), IntermediateFieldType.Number),
21 new IntermediateFieldDefinition(nameof(NetFxNativeImageTupleFields.Attributes), IntermediateFieldType.Number),
22 new IntermediateFieldDefinition(nameof(NetFxNativeImageTupleFields.File_Application), IntermediateFieldType.String),
23 new IntermediateFieldDefinition(nameof(NetFxNativeImageTupleFields.Directory_ApplicationBase), IntermediateFieldType.String),
24 },
25 typeof(NetFxNativeImageTuple));
26 }
27}
diff --git a/src/wixext/WixToolset.Netfx.wixext.csproj b/src/wixext/WixToolset.Netfx.wixext.csproj
new file mode 100644
index 00000000..d925e348
--- /dev/null
+++ b/src/wixext/WixToolset.Netfx.wixext.csproj
@@ -0,0 +1,35 @@
1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. -->
3
4<Project Sdk="Microsoft.NET.Sdk">
5 <PropertyGroup>
6 <TargetFramework>netstandard2.0</TargetFramework>
7 <RootNamespace>WixToolset.Netfx</RootNamespace>
8 <Description>WiX Toolset .NET Framework Extension</Description>
9 <Title>WiX Toolset .NET Framework Extension</Title>
10 <IsTool>true</IsTool>
11 <ContentTargetFolders>build</ContentTargetFolders>
12 </PropertyGroup>
13
14 <ItemGroup>
15 <Content Include="$(MSBuildThisFileName).targets" />
16 <Content Include="netfx.xsd" PackagePath="tools" />
17 <EmbeddedResource Include="$(OutputPath)..\netfx.wixlib" />
18 </ItemGroup>
19
20 <ItemGroup>
21 <ProjectReference Include="$(WixToolsetRootFolder)\Data\src\WixToolset.Data\WixToolset.Data.csproj" Condition=" '$(Configuration)' == 'Debug' And Exists('$(WixToolsetRootFolder)\Data\README.md') " />
22 <PackageReference Include="WixToolset.Data" Version="4.0.*" Condition=" '$(Configuration)' == 'Release' Or !Exists('$(WixToolsetRootFolder)\Data\README.md') " PrivateAssets="all" />
23
24 <ProjectReference Include="$(WixToolsetRootFolder)\Extensibility\src\WixToolset.Extensibility\WixToolset.Extensibility.csproj" Condition=" '$(Configuration)' == 'Debug' And Exists('$(WixToolsetRootFolder)\Extensibility\README.md') " />
25 <PackageReference Include="WixToolset.Extensibility" Version="4.0.*" Condition=" '$(Configuration)' == 'Release' Or !Exists('$(WixToolsetRootFolder)\Extensibility\README.md') " PrivateAssets="all" />
26 </ItemGroup>
27
28 <ItemGroup>
29 <ProjectReference Include="..\wixlib\netfx.wixproj" ReferenceOutputAssembly="false" />
30 </ItemGroup>
31
32 <ItemGroup>
33 <PackageReference Include="Nerdbank.GitVersioning" Version="2.1.7" PrivateAssets="all" />
34 </ItemGroup>
35</Project>
diff --git a/src/wixext/WixToolset.Netfx.wixext.targets b/src/wixext/WixToolset.Netfx.wixext.targets
new file mode 100644
index 00000000..17312abf
--- /dev/null
+++ b/src/wixext/WixToolset.Netfx.wixext.targets
@@ -0,0 +1,11 @@
1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. -->
3
4<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0">
5 <PropertyGroup>
6 <WixToolsetNetfxWixextPath Condition=" '$(WixToolsetNetfxWixextPath)' == '' ">$(MSBuildThisFileDirectory)..\tools\WixToolset.Netfx.wixext.dll"</WixToolsetNetfxWixextPath>
7 </PropertyGroup>
8 <ItemGroup>
9 <WixExtension Include="$(WixToolsetNetfxWixextPath)" />
10 </ItemGroup>
11</Project>
diff --git a/src/wixext/netfx.xsd b/src/wixext/netfx.xsd
new file mode 100644
index 00000000..6ef4e9b6
--- /dev/null
+++ b/src/wixext/netfx.xsd
@@ -0,0 +1,235 @@
1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. -->
3
4
5<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
6 xmlns:xse=" http://wixtoolset.org/schemas/XmlSchemaExtension"
7 xmlns:html="http://www.w3.org/1999/xhtml"
8 targetNamespace="http://wixtoolset.org/schemas/v4/wxs/netfx"
9 xmlns="http://wixtoolset.org/schemas/v4/wxs/netfx">
10 <xs:annotation>
11 <xs:documentation>
12 The source code schema for the WiX Toolset .NET Framework Extension.
13 </xs:documentation>
14 </xs:annotation>
15
16 <xs:element name="NativeImage">
17 <xs:annotation>
18 <xs:documentation>
19 Improves the performance of managed applications by creating native images.
20 Requires the .NET Framework 2.0 or newer to be installed on the target machine since
21 it runs <html:a href="http://msdn.microsoft.com/en-us/library/6t9t5wcf.aspx">NGen</html:a>.
22 </xs:documentation>
23 <xs:appinfo>
24 <xse:parent namespace="http://wixtoolset.org/schemas/v4/wxs" ref="File" />
25 <xse:remarks>
26 <html:p>
27 Native images are files containing compiled processor-specific machine code, which
28 are installed into the native image cache on the local computer. The runtime
29 can use native images from the cache instead using the just-in-time (JIT)
30 compiler to compile the original assembly.
31 </html:p>
32 <html:p>
33 The native image custom actions are configured to ignore failures so that failing
34 to generate or remove a native image will not cause setup to fail and roll back.
35 </html:p>
36 <html:p>
37 <html:b>Note for patches:</html:b> if you built your target, or baseline, MSI with
38 previous versions 3.0 or 3.5 of this extension and want to upgrade to formattable
39 values for @AssemblyApplication or @AppBaseDirectory you must also include a
40 BinaryRef to "NetFxCA" to pull in necessary changes. If you do use formattable
41 values and do not include the binary changes ngen.exe will not optimize your
42 native images for the specified application.
43 </html:p>
44 <html:p>
45 This should be a rare occurrence, however. Because you cannot remove components
46 in a patch - and pyro does validate you do not - it is not practical to switch
47 from using identifiers to formattable values in a patch. One practical possibility
48 is if you wanted to use a different application to optimize your native images
49 and that application is not already installed with the MSI to be updated.
50 </html:p>
51 </xse:remarks>
52 </xs:appinfo>
53 </xs:annotation>
54 <xs:complexType>
55 <xs:attribute name="Id" type="xs:string" use="required">
56 <xs:annotation>
57 <xs:documentation>
58 The identifier for this NativeImage.
59 </xs:documentation>
60 </xs:annotation>
61 </xs:attribute>
62 <xs:attribute name="AppBaseDirectory" type="xs:string">
63 <xs:annotation>
64 <xs:documentation>
65 <html:p>
66 The directory to use for locating dependent assemblies.
67 For DLL assemblies and assemblies installed to the Global Assembly Cache (GAC),
68 this attribute should be set to the directory of the application which loads this
69 assembly. For EXE assemblies, this attribute does not need to be set because NGen
70 will use the directory of the assembly file by default.
71 </html:p>
72 <html:p>
73 The value can be in the form of a directory identifier, or a formatted string
74 that resolves to either a directory identifier or a full path to a directory.
75 </html:p>
76 </xs:documentation>
77 </xs:annotation>
78 </xs:attribute>
79 <xs:attribute name="AssemblyApplication" type="xs:string">
80 <xs:annotation>
81 <xs:documentation>
82 <html:p>
83 The application which will load this assembly.
84 For DLL assemblies which are loaded via reflection, this attribute should
85 be set to indicate the application which will load this assembly.
86 The configuration of the application (usually specified via an exe.config file) will be used
87 to determine how to resolve dependencies for this assembly.
88 </html:p>
89 <html:p>
90 The value can be in the form of a file identifier, or a formatted string
91 that resolves to either a file identifier or a full path to a file.
92 </html:p>
93 <html:p>
94 When a shared component is loaded at run time, using the Load method, the
95 application's configuration file determines the dependencies that are loaded
96 for the shared component — for example, the version of a dependency that is loaded.
97 This attribute gives guidance on which dependencies would be loaded at run time in order
98 to figure out which dependency assemblies will also need to have native images generated
99 (assuming the Dependency attribute is not set to "no").
100 </html:p>
101 <html:p>
102 This attribute cannot be set if the AssemblyApplication attribute is set on the parent
103 File element (please note that these attributes both refer to the same application
104 assembly but do very different things: specifiying File/@AssemblyApplication will force
105 an assembly to install to a private location next to the indicated application, whereas
106 this AssemblyApplication attribute will be used to help resolve dependent assemblies
107 while generating native images for this assembly).
108 </html:p>
109 </xs:documentation>
110 </xs:annotation>
111 </xs:attribute>
112 <xs:attribute name="Debug" type="YesNoType">
113 <xs:annotation>
114 <xs:documentation>
115 Set to "yes" to generate native images that can be used under a debugger.
116 The default value is "no".
117 </xs:documentation>
118 </xs:annotation>
119 </xs:attribute>
120 <xs:attribute name="Dependencies" type="YesNoType">
121 <xs:annotation>
122 <xs:documentation>
123 Set to "no" to generate the minimum number of native images.
124 The default value is "yes".
125 </xs:documentation>
126 </xs:annotation>
127 </xs:attribute>
128 <xs:attribute name="Platform">
129 <xs:annotation>
130 <xs:documentation>
131 Sets the platform(s) for which native images will be generated.
132 </xs:documentation>
133 </xs:annotation>
134 <xs:simpleType>
135 <xs:restriction base="xs:NMTOKEN">
136 <xs:enumeration value="32bit">
137 <xs:annotation>
138 <xs:documentation>
139 Attempt to generate native images only for the 32-bit version of the .NET Framework
140 on the target machine. If the 32-bit version of the .NET Framework 2.0 or newer is not
141 present on the target machine, native image custom actions will not be scheduled.
142 This is the default value.
143 </xs:documentation>
144 </xs:annotation>
145 </xs:enumeration>
146 <xs:enumeration value="64bit">
147 <xs:annotation>
148 <xs:documentation>
149 Attempt to generate native images only for the 64-bit version of the .NET Framework
150 on the target machine. If a 64-bit version of the .NET Framework 2.0 or newer is not
151 present on the target machine, native image custom actions will not be scheduled.
152 </xs:documentation>
153 </xs:annotation>
154 </xs:enumeration>
155 <xs:enumeration value="all">
156 <xs:annotation>
157 <xs:documentation>
158 Attempt to generate native images for the 32-bit and 64-bit versions of the .NET Framework
159 on the target machine. If a version of the .NET Framework 2.0 or newer is not present on the
160 target machine for a processor architecture, native image custom actions will not be
161 scheduled for that processor architecture.
162 </xs:documentation>
163 </xs:annotation>
164 </xs:enumeration>
165 </xs:restriction>
166 </xs:simpleType>
167 </xs:attribute>
168 <xs:attribute name="Priority">
169 <xs:annotation>
170 <xs:documentation>
171 Sets the priority of generating the native images for this assembly.
172 </xs:documentation>
173 </xs:annotation>
174 <xs:simpleType>
175 <xs:restriction base="xs:NMTOKEN">
176 <xs:enumeration value="0">
177 <xs:annotation>
178 <xs:documentation>
179 This is the highest priority, it means that image generation occurs syncronously
180 during the setup process. This option will slow down setup performance.
181 </xs:documentation>
182 </xs:annotation>
183 </xs:enumeration>
184 <xs:enumeration value="1">
185 <xs:annotation>
186 <xs:documentation>
187 This will queue image generation to the NGen service to occur immediately.
188 This option will slow down setup performance.
189 </xs:documentation>
190 </xs:annotation>
191 </xs:enumeration>
192 <xs:enumeration value="2">
193 <xs:annotation>
194 <xs:documentation>
195 This will queue image generation to the NGen service to occur after all priority 1
196 assemblies have completed.
197 This option will slow down setup performance.
198 </xs:documentation>
199 </xs:annotation>
200 </xs:enumeration>
201 <xs:enumeration value="3">
202 <xs:annotation>
203 <xs:documentation>
204 This is the lowest priority, it will queue image generation to occur when the
205 machine is idle.
206 This option should not slow down setup performance.
207 This is the default value.
208 </xs:documentation>
209 </xs:annotation>
210 </xs:enumeration>
211 </xs:restriction>
212 </xs:simpleType>
213 </xs:attribute>
214 <xs:attribute name="Profile" type="YesNoType">
215 <xs:annotation>
216 <xs:documentation>
217 Set to "yes" to generate native images that can be used under a profiler.
218 The default value is "no".
219 </xs:documentation>
220 </xs:annotation>
221 </xs:attribute>
222 </xs:complexType>
223 </xs:element>
224
225 <xs:simpleType name="YesNoType">
226 <xs:annotation>
227 <xs:documentation>Values of this type will either be "yes" or "no".</xs:documentation>
228 </xs:annotation>
229 <xs:restriction base='xs:NMTOKEN'>
230 <xs:enumeration value="no"/>
231 <xs:enumeration value="yes"/>
232 </xs:restriction>
233 </xs:simpleType>
234
235</xs:schema>
diff --git a/src/wixlib/NetFx1.1.wxs b/src/wixlib/NetFx1.1.wxs
new file mode 100644
index 00000000..406aef3f
--- /dev/null
+++ b/src/wixlib/NetFx1.1.wxs
@@ -0,0 +1,192 @@
1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. -->
3
4
5<Wix xmlns="http://wixtoolset.org/schemas/v4/wxs">
6
7 <!--
8 .NET Framework installation state properties
9
10 Official documentation can be found at the following location:
11
12 .NET Framework 1.1 - http://msdn.microsoft.com/library/ms994339.aspx
13 -->
14
15 <!-- set to #1 if the .NET Framework 1.1 is installed (not set otherwise) -->
16 <Fragment>
17 <Property Id="NETFRAMEWORK11" Secure="yes">
18 <RegistrySearch Id="NetFramework11" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v1.1.4322" Name="Install" Type="raw" />
19 </Property>
20 </Fragment>
21
22 <!-- Indicates the service pack level for the .NET Framework 1.1. -->
23 <Fragment>
24 <Property Id="NETFRAMEWORK11_SP_LEVEL" Secure="yes">
25 <RegistrySearch Id="NetFramework11SP" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v1.1.4322" Name="SP" Type="raw" />
26 </Property>
27 </Fragment>
28
29 <!-- Location of .NET Framework 1.1 redistributable install root directory -->
30 <Fragment>
31 <Property Id="NETFRAMEWORK11INSTALLROOTDIR" Secure="yes">
32 <RegistrySearch Id="NetFxInstallRootForNetfx11Search" Type="raw" Root="HKLM" Key="Software\Microsoft\.NETFramework" Name="InstallRoot">
33 <DirectorySearch Id="NetFx11InstallRootSearch" Path="v1.1.4322" Depth="0" />
34 </RegistrySearch>
35 </Property>
36 </Fragment>
37
38 <!-- set to #1 if the .NET Framework 1.1 Chinese (Simplified) language pack is installed (not set otherwise) -->
39 <Fragment>
40 <Property Id="NETFRAMEWORK11_ZH_CN_LANGPACK" Secure="yes">
41 <RegistrySearch Id="NetFramework11ZhCnLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v1.1.4322\2052" Name="Install" Type="raw" />
42 </Property>
43 </Fragment>
44
45 <!-- set to #1 if the .NET Framework 1.1 Chinese (Traditional) language pack is installed (not set otherwise) -->
46 <Fragment>
47 <Property Id="NETFRAMEWORK11_ZH_TW_LANGPACK" Secure="yes">
48 <RegistrySearch Id="NetFramework11ZhTwLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v1.1.4322\1028" Name="Install" Type="raw" />
49 </Property>
50 </Fragment>
51
52 <!-- set to #1 if the .NET Framework 1.1 Czech language pack is installed (not set otherwise) -->
53 <Fragment>
54 <Property Id="NETFRAMEWORK11_CS_CZ_LANGPACK" Secure="yes">
55 <RegistrySearch Id="NetFramework11CsCzLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v1.1.4322\1029" Name="Install" Type="raw" />
56 </Property>
57 </Fragment>
58
59 <!-- set to #1 if the .NET Framework 1.1 Danish language pack is installed (not set otherwise) -->
60 <Fragment>
61 <Property Id="NETFRAMEWORK11_DA_DK_LANGPACK" Secure="yes">
62 <RegistrySearch Id="NetFramework11DaDkLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v1.1.4322\1030" Name="Install" Type="raw" />
63 </Property>
64 </Fragment>
65
66 <!-- set to #1 if the .NET Framework 1.1 Dutch language pack is installed (not set otherwise) -->
67 <Fragment>
68 <Property Id="NETFRAMEWORK11_NL_NL_LANGPACK" Secure="yes">
69 <RegistrySearch Id="NetFramework11NlNlLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v1.1.4322\1043" Name="Install" Type="raw" />
70 </Property>
71 </Fragment>
72
73 <!-- set to #1 if the .NET Framework 1.1 Finnish language pack is installed (not set otherwise) -->
74 <Fragment>
75 <Property Id="NETFRAMEWORK11_FI_FI_LANGPACK" Secure="yes">
76 <RegistrySearch Id="NetFramework11FiFiLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v1.1.4322\1035" Name="Install" Type="raw" />
77 </Property>
78 </Fragment>
79
80 <!-- set to #1 if the .NET Framework 1.1 French language pack is installed (not set otherwise) -->
81 <Fragment>
82 <Property Id="NETFRAMEWORK11_FR_FR_LANGPACK" Secure="yes">
83 <RegistrySearch Id="NetFramework11FrFrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v1.1.4322\1036" Name="Install" Type="raw" />
84 </Property>
85 </Fragment>
86
87 <!-- set to #1 if the .NET Framework 1.1 German language pack is installed (not set otherwise) -->
88 <Fragment>
89 <Property Id="NETFRAMEWORK11_DE_DE_LANGPACK" Secure="yes">
90 <RegistrySearch Id="NetFramework11DeDeLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v1.1.4322\1031" Name="Install" Type="raw" />
91 </Property>
92 </Fragment>
93
94 <!-- set to #1 if the .NET Framework 1.1 Greek language pack is installed (not set otherwise) -->
95 <Fragment>
96 <Property Id="NETFRAMEWORK11_EL_GR_LANGPACK" Secure="yes">
97 <RegistrySearch Id="NetFramework11ElGrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v1.1.4322\1032" Name="Install" Type="raw" />
98 </Property>
99 </Fragment>
100
101 <!-- set to #1 if the .NET Framework 1.1 Hungarian language pack is installed (not set otherwise) -->
102 <Fragment>
103 <Property Id="NETFRAMEWORK11_HU_HU_LANGPACK" Secure="yes">
104 <RegistrySearch Id="NetFramework11HuHuLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v1.1.4322\1038" Name="Install" Type="raw" />
105 </Property>
106 </Fragment>
107
108 <!-- set to #1 if the .NET Framework 1.1 Italian language pack is installed (not set otherwise) -->
109 <Fragment>
110 <Property Id="NETFRAMEWORK11_IT_IT_LANGPACK" Secure="yes">
111 <RegistrySearch Id="NetFramework11ItItLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v1.1.4322\1040" Name="Install" Type="raw" />
112 </Property>
113 </Fragment>
114
115 <!-- set to #1 if the .NET Framework 1.1 Japanese language pack is installed (not set otherwise) -->
116 <Fragment>
117 <Property Id="NETFRAMEWORK11_JA_JP_LANGPACK" Secure="yes">
118 <RegistrySearch Id="NetFramework11JaJpLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v1.1.4322\1041" Name="Install" Type="raw" />
119 </Property>
120 </Fragment>
121
122 <!-- set to #1 if the .NET Framework 1.1 Korean language pack is installed (not set otherwise) -->
123 <Fragment>
124 <Property Id="NETFRAMEWORK11_KO_KR_LANGPACK" Secure="yes">
125 <RegistrySearch Id="NetFramework11KoKrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v1.1.4322\1042" Name="Install" Type="raw" />
126 </Property>
127 </Fragment>
128
129 <!-- set to #1 if the .NET Framework 1.1 Norwegian language pack is installed (not set otherwise) -->
130 <Fragment>
131 <Property Id="NETFRAMEWORK11_NB_NO_LANGPACK" Secure="yes">
132 <RegistrySearch Id="NetFramework11NbNoLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v1.1.4322\1044" Name="Install" Type="raw" />
133 </Property>
134 </Fragment>
135
136 <!-- set to #1 if the .NET Framework 1.1 Polish language pack is installed (not set otherwise) -->
137 <Fragment>
138 <Property Id="NETFRAMEWORK11_PL_PL_LANGPACK" Secure="yes">
139 <RegistrySearch Id="NetFramework11PlPlLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v1.1.4322\1045" Name="Install" Type="raw" />
140 </Property>
141 </Fragment>
142
143 <!-- set to #1 if the .NET Framework 1.1 Portuguese (Brazil) language pack is installed (not set otherwise) -->
144 <Fragment>
145 <Property Id="NETFRAMEWORK11_PT_BR_LANGPACK" Secure="yes">
146 <RegistrySearch Id="NetFramework11PtBrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v1.1.4322\1046" Name="Install" Type="raw" />
147 </Property>
148 </Fragment>
149
150 <!-- set to #1 if the .NET Framework 1.1 Portuguese (Portugal) language pack is installed (not set otherwise) -->
151 <Fragment>
152 <Property Id="NETFRAMEWORK11_PT_PT_LANGPACK" Secure="yes">
153 <RegistrySearch Id="NetFramework11PtPtLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v1.1.4322\2070" Name="Install" Type="raw" />
154 </Property>
155 </Fragment>
156
157 <!-- set to #1 if the .NET Framework 1.1 Russian language pack is installed (not set otherwise) -->
158 <Fragment>
159 <Property Id="NETFRAMEWORK11_RU_RU_LANGPACK" Secure="yes">
160 <RegistrySearch Id="NetFramework11RuRuLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v1.1.4322\1049" Name="Install" Type="raw" />
161 </Property>
162 </Fragment>
163
164 <!-- set to #1 if the .NET Framework 1.1 Spanish language pack is installed (not set otherwise) -->
165 <Fragment>
166 <Property Id="NETFRAMEWORK11_ES_ES_LANGPACK" Secure="yes">
167 <RegistrySearch Id="NetFramework11EsEsLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v1.1.4322\3082" Name="Install" Type="raw" />
168 </Property>
169 </Fragment>
170
171 <!-- set to #1 if the .NET Framework 1.1 Swedish language pack is installed (not set otherwise) -->
172 <Fragment>
173 <Property Id="NETFRAMEWORK11_SV_SE_LANGPACK" Secure="yes">
174 <RegistrySearch Id="NetFramework11SvSeLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v1.1.4322\1053" Name="Install" Type="raw" />
175 </Property>
176 </Fragment>
177
178 <!-- set to #1 if the .NET Framework 1.1 Turkish language pack is installed (not set otherwise) -->
179 <Fragment>
180 <Property Id="NETFRAMEWORK11_TR_TR_LANGPACK" Secure="yes">
181 <RegistrySearch Id="NetFramework11TrTrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v1.1.4322\1055" Name="Install" Type="raw" />
182 </Property>
183 </Fragment>
184
185 <!-- location of the .NET Framework 1.1 SDK installation root -->
186 <Fragment>
187 <Property Id="NETFRAMEWORK11SDKDIR" Secure="yes">
188 <RegistrySearch Id="NetFramework11SDKDir" Root="HKLM" Key="Software\Microsoft\.NETFramework" Name="sdkInstallRootv1.1" Type="raw" />
189 </Property>
190 </Fragment>
191
192</Wix>
diff --git a/src/wixlib/NetFx1.wxs b/src/wixlib/NetFx1.wxs
new file mode 100644
index 00000000..c1b266e8
--- /dev/null
+++ b/src/wixlib/NetFx1.wxs
@@ -0,0 +1,31 @@
1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. -->
3
4
5<Wix xmlns="http://wixtoolset.org/schemas/v4/wxs">
6
7 <!--
8 .NET Framework installation state properties
9
10 Official documentation can be found at the following location:
11
12 .NET Framework 1.0 - http://msdn.microsoft.com/library/ms994349.aspx
13 -->
14
15 <!-- set to 3321-3705 if the .NET Framework 1.0 is installed (not set otherwise) -->
16 <Fragment>
17 <Property Id="NETFRAMEWORK10" Secure="yes">
18 <RegistrySearch Id="NetFramework10" Root="HKLM" Key="SOFTWARE\Microsoft\.NETFramework\policy\v1.0" Name="3705" Type="raw" />
19 </Property>
20 </Fragment>
21
22 <!-- Location of .NET Framework 1.0 redistributable install root directory -->
23 <Fragment>
24 <Property Id="NETFRAMEWORK10INSTALLROOTDIR" Secure="yes">
25 <RegistrySearch Id="NetFxInstallRootForNetfx10Search" Type="raw" Root="HKLM" Key="Software\Microsoft\.NETFramework" Name="InstallRoot">
26 <DirectorySearch Id="NetFx10InstallRootSearch" Path="v1.0.3705" Depth="0" />
27 </RegistrySearch>
28 </Property>
29 </Fragment>
30
31</Wix>
diff --git a/src/wixlib/NetFx2.wxs b/src/wixlib/NetFx2.wxs
new file mode 100644
index 00000000..92386b02
--- /dev/null
+++ b/src/wixlib/NetFx2.wxs
@@ -0,0 +1,201 @@
1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. -->
3
4
5<Wix xmlns="http://wixtoolset.org/schemas/v4/wxs">
6
7 <!--
8 .NET Framework installation state properties
9
10 Official documentation can be found at the following location:
11
12 .NET Framework 2.0 - http://msdn.microsoft.com/library/aa480243.aspx
13 -->
14
15 <!-- set to #1 if the .NET Framework 2.0 is installed (not set otherwise) -->
16 <Fragment>
17 <Property Id="NETFRAMEWORK20" Secure="yes">
18 <RegistrySearch Id="NetFramework20" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v2.0.50727" Name="Install" Type="raw" />
19 </Property>
20 </Fragment>
21
22 <!-- Indicates the service pack level for the .NET Framework 2.0. -->
23 <Fragment>
24 <Property Id="NETFRAMEWORK20_SP_LEVEL" Secure="yes">
25 <RegistrySearch Id="NetFramework20SP" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v2.0.50727" Name="SP" Type="raw" />
26 </Property>
27 </Fragment>
28
29 <!-- Location of .NET Framework 2.0 redistributable install root directory -->
30 <Fragment>
31 <Property Id="NETFRAMEWORK20INSTALLROOTDIR" Secure="yes">
32 <RegistrySearch Id="NetFxInstallRootForNetfx20Search" Type="raw" Root="HKLM" Key="Software\Microsoft\.NETFramework" Name="InstallRoot">
33 <DirectorySearch Id="NetFx20InstallRootSearch" Path="v2.0.50727" Depth="0" />
34 </RegistrySearch>
35 </Property>
36 </Fragment>
37
38 <!-- Location of .NET Framework 2.0 (64-bit) redistributable install root directory -->
39 <Fragment>
40 <Property Id="NETFRAMEWORK20INSTALLROOTDIR64" Secure="yes">
41 <RegistrySearch Id="NetFxInstallRootForNetfx20Search64" Type="raw" Root="HKLM" Key="Software\Microsoft\.NETFramework" Name="InstallRoot" Win64="yes">
42 <DirectorySearch Id="NetFx20InstallRootSearch64" Path="v2.0.50727" Depth="0" />
43 </RegistrySearch>
44 </Property>
45 </Fragment>
46
47 <!-- set to #1 if the .NET Framework 2.0 Chinese (Simplified) language pack is installed (not set otherwise) -->
48 <Fragment>
49 <Property Id="NETFRAMEWORK20_ZH_CN_LANGPACK" Secure="yes">
50 <RegistrySearch Id="NETFRAMEWORK20ZhCnLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v2.0.50727\2052" Name="Install" Type="raw" />
51 </Property>
52 </Fragment>
53
54 <!-- set to #1 if the .NET Framework 2.0 Chinese (Traditional) language pack is installed (not set otherwise) -->
55 <Fragment>
56 <Property Id="NETFRAMEWORK20_ZH_TW_LANGPACK" Secure="yes">
57 <RegistrySearch Id="NETFRAMEWORK20ZhTwLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v2.0.50727\1028" Name="Install" Type="raw" />
58 </Property>
59 </Fragment>
60
61 <!-- set to #1 if the .NET Framework 2.0 Czech language pack is installed (not set otherwise) -->
62 <Fragment>
63 <Property Id="NETFRAMEWORK20_CS_CZ_LANGPACK" Secure="yes">
64 <RegistrySearch Id="NETFRAMEWORK20CsCzLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v2.0.50727\1029" Name="Install" Type="raw" />
65 </Property>
66 </Fragment>
67
68 <!-- set to #1 if the .NET Framework 2.0 Danish language pack is installed (not set otherwise) -->
69 <Fragment>
70 <Property Id="NETFRAMEWORK20_DA_DK_LANGPACK" Secure="yes">
71 <RegistrySearch Id="NETFRAMEWORK20DaDkLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v2.0.50727\1030" Name="Install" Type="raw" />
72 </Property>
73 </Fragment>
74
75 <!-- set to #1 if the .NET Framework 2.0 Dutch language pack is installed (not set otherwise) -->
76 <Fragment>
77 <Property Id="NETFRAMEWORK20_NL_NL_LANGPACK" Secure="yes">
78 <RegistrySearch Id="NETFRAMEWORK20NlNlLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v2.0.50727\1043" Name="Install" Type="raw" />
79 </Property>
80 </Fragment>
81
82 <!-- set to #1 if the .NET Framework 2.0 Finnish language pack is installed (not set otherwise) -->
83 <Fragment>
84 <Property Id="NETFRAMEWORK20_FI_FI_LANGPACK" Secure="yes">
85 <RegistrySearch Id="NETFRAMEWORK20FiFiLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v2.0.50727\1035" Name="Install" Type="raw" />
86 </Property>
87 </Fragment>
88
89 <!-- set to #1 if the .NET Framework 2.0 French language pack is installed (not set otherwise) -->
90 <Fragment>
91 <Property Id="NETFRAMEWORK20_FR_FR_LANGPACK" Secure="yes">
92 <RegistrySearch Id="NETFRAMEWORK20FrFrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v2.0.50727\1036" Name="Install" Type="raw" />
93 </Property>
94 </Fragment>
95
96 <!-- set to #1 if the .NET Framework 2.0 German language pack is installed (not set otherwise) -->
97 <Fragment>
98 <Property Id="NETFRAMEWORK20_DE_DE_LANGPACK" Secure="yes">
99 <RegistrySearch Id="NETFRAMEWORK20DeDeLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v2.0.50727\1031" Name="Install" Type="raw" />
100 </Property>
101 </Fragment>
102
103 <!-- set to #1 if the .NET Framework 2.0 Greek language pack is installed (not set otherwise) -->
104 <Fragment>
105 <Property Id="NETFRAMEWORK20_EL_GR_LANGPACK" Secure="yes">
106 <RegistrySearch Id="NETFRAMEWORK20ElGrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v2.0.50727\1032" Name="Install" Type="raw" />
107 </Property>
108 </Fragment>
109
110 <!-- set to #1 if the .NET Framework 2.0 Hungarian language pack is installed (not set otherwise) -->
111 <Fragment>
112 <Property Id="NETFRAMEWORK20_HU_HU_LANGPACK" Secure="yes">
113 <RegistrySearch Id="NETFRAMEWORK20HuHuLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v2.0.50727\1038" Name="Install" Type="raw" />
114 </Property>
115 </Fragment>
116
117 <!-- set to #1 if the .NET Framework 2.0 Italian language pack is installed (not set otherwise) -->
118 <Fragment>
119 <Property Id="NETFRAMEWORK20_IT_IT_LANGPACK" Secure="yes">
120 <RegistrySearch Id="NETFRAMEWORK20ItItLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v2.0.50727\1040" Name="Install" Type="raw" />
121 </Property>
122 </Fragment>
123
124 <!-- set to #1 if the .NET Framework 2.0 Japanese language pack is installed (not set otherwise) -->
125 <Fragment>
126 <Property Id="NETFRAMEWORK20_JA_JP_LANGPACK" Secure="yes">
127 <RegistrySearch Id="NETFRAMEWORK20JaJpLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v2.0.50727\1041" Name="Install" Type="raw" />
128 </Property>
129 </Fragment>
130
131 <!-- set to #1 if the .NET Framework 2.0 Korean language pack is installed (not set otherwise) -->
132 <Fragment>
133 <Property Id="NETFRAMEWORK20_KO_KR_LANGPACK" Secure="yes">
134 <RegistrySearch Id="NETFRAMEWORK20KoKrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v2.0.50727\1042" Name="Install" Type="raw" />
135 </Property>
136 </Fragment>
137
138 <!-- set to #1 if the .NET Framework 2.0 Norwegian language pack is installed (not set otherwise) -->
139 <Fragment>
140 <Property Id="NETFRAMEWORK20_NB_NO_LANGPACK" Secure="yes">
141 <RegistrySearch Id="NETFRAMEWORK20NbNoLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v2.0.50727\1044" Name="Install" Type="raw" />
142 </Property>
143 </Fragment>
144
145 <!-- set to #1 if the .NET Framework 2.0 Polish language pack is installed (not set otherwise) -->
146 <Fragment>
147 <Property Id="NETFRAMEWORK20_PL_PL_LANGPACK" Secure="yes">
148 <RegistrySearch Id="NETFRAMEWORK20PlPlLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v2.0.50727\1045" Name="Install" Type="raw" />
149 </Property>
150 </Fragment>
151
152 <!-- set to #1 if the .NET Framework 2.0 Portuguese (Brazil) language pack is installed (not set otherwise) -->
153 <Fragment>
154 <Property Id="NETFRAMEWORK20_PT_BR_LANGPACK" Secure="yes">
155 <RegistrySearch Id="NETFRAMEWORK20PtBrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v2.0.50727\1046" Name="Install" Type="raw" />
156 </Property>
157 </Fragment>
158
159 <!-- set to #1 if the .NET Framework 2.0 Portuguese (Portugal) language pack is installed (not set otherwise) -->
160 <Fragment>
161 <Property Id="NETFRAMEWORK20_PT_PT_LANGPACK" Secure="yes">
162 <RegistrySearch Id="NETFRAMEWORK20PtPtLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v2.0.50727\2070" Name="Install" Type="raw" />
163 </Property>
164 </Fragment>
165
166 <!-- set to #1 if the .NET Framework 2.0 Russian language pack is installed (not set otherwise) -->
167 <Fragment>
168 <Property Id="NETFRAMEWORK20_RU_RU_LANGPACK" Secure="yes">
169 <RegistrySearch Id="NETFRAMEWORK20RuRuLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v2.0.50727\1049" Name="Install" Type="raw" />
170 </Property>
171 </Fragment>
172
173 <!-- set to #1 if the .NET Framework 2.0 Spanish language pack is installed (not set otherwise) -->
174 <Fragment>
175 <Property Id="NETFRAMEWORK20_ES_ES_LANGPACK" Secure="yes">
176 <RegistrySearch Id="NETFRAMEWORK20EsEsLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v2.0.50727\3082" Name="Install" Type="raw" />
177 </Property>
178 </Fragment>
179
180 <!-- set to #1 if the .NET Framework 2.0 Swedish language pack is installed (not set otherwise) -->
181 <Fragment>
182 <Property Id="NETFRAMEWORK20_SV_SE_LANGPACK" Secure="yes">
183 <RegistrySearch Id="NETFRAMEWORK20SvSeLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v2.0.50727\1053" Name="Install" Type="raw" />
184 </Property>
185 </Fragment>
186
187 <!-- set to #1 if the .NET Framework 2.0 Turkish language pack is installed (not set otherwise) -->
188 <Fragment>
189 <Property Id="NETFRAMEWORK20_TR_TR_LANGPACK" Secure="yes">
190 <RegistrySearch Id="NETFRAMEWORK20TrTrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v2.0.50727\1055" Name="Install" Type="raw" />
191 </Property>
192 </Fragment>
193
194 <!-- location of the .NET Framework 2.0 SDK installation root -->
195 <Fragment>
196 <Property Id="NETFRAMEWORK20SDKDIR" Secure="yes">
197 <RegistrySearch Id="NetFramework20SDKDir" Root="HKLM" Key="Software\Microsoft\.NETFramework" Name="sdkInstallRootv2.0" Type="raw" />
198 </Property>
199 </Fragment>
200
201</Wix>
diff --git a/src/wixlib/NetFx3.5.wxs b/src/wixlib/NetFx3.5.wxs
new file mode 100644
index 00000000..422608da
--- /dev/null
+++ b/src/wixlib/NetFx3.5.wxs
@@ -0,0 +1,241 @@
1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. -->
3
4
5<Wix xmlns="http://wixtoolset.org/schemas/v4/wxs" xmlns:util="http://wixtoolset.org/schemas/v4/wxs/util">
6
7 <!--
8 .NET Framework installation state properties
9
10 Official documentation can be found at the following locations:
11
12 .NET Framework 3.5 - http://msdn.microsoft.com/library/cc160716.aspx
13 .NET Framework 3.5 client profile - http://download.microsoft.com/download/5/a/a/5aa86d6c-969b-42d8-bc6b-30e02bfeccf0/NETFXClientProfile_DeploymentGuide.htm
14 -->
15
16 <!-- Indicates the service pack level for the .NET Framework 3.5 (for bundles). -->
17 <Fragment>
18 <util:RegistrySearch
19 Id="NETFRAMEWORK35_SP_LEVEL"
20 Variable="NETFRAMEWORK35_SP_LEVEL"
21 Root="HKLM"
22 Key="Software\Microsoft\NET Framework Setup\NDP\v3.5"
23 Value="SP"
24 Result="value" />
25 </Fragment>
26
27 <!-- set to #1 if the .NET Framework 3.5 is installed (not set otherwise) -->
28 <Fragment>
29 <Property Id="NETFRAMEWORK35" Secure="yes">
30 <RegistrySearch Id="NetFramework35" Root="HKLM" Key="SOFTWARE\Microsoft\NET Framework Setup\NDP\v3.5" Name="Install" Type="raw" />
31 </Property>
32 </Fragment>
33
34 <!-- Indicates the service pack level for the .NET Framework 3.5. -->
35 <Fragment>
36 <Property Id="NETFRAMEWORK35_SP_LEVEL" Secure="yes">
37 <RegistrySearch Id="NetFramework35SP" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.5" Name="SP" Type="raw" />
38 </Property>
39 </Fragment>
40
41 <!-- Location of .NET Framework 3.5 redistributable install root directory -->
42 <Fragment>
43 <Property Id="NETFRAMEWORK35INSTALLROOTDIR" Secure="yes">
44 <RegistrySearch Id="NetFxInstallRootForNetfx35Search" Type="raw" Root="HKLM" Key="Software\Microsoft\.NETFramework" Name="InstallRoot">
45 <DirectorySearch Id="NetFx35InstallRootSearch" Path="v3.5" Depth="0" />
46 </RegistrySearch>
47 </Property>
48 </Fragment>
49
50 <!-- Location of .NET Framework 3.5 (64-bit) redistributable install root directory -->
51 <Fragment>
52 <Property Id="NETFRAMEWORK35INSTALLROOTDIR64" Secure="yes">
53 <RegistrySearch Id="NetFxInstallRootForNetfx35Search64" Type="raw" Root="HKLM" Key="Software\Microsoft\.NETFramework" Name="InstallRoot" Win64="yes">
54 <DirectorySearch Id="NetFx35InstallRootSearch64" Path="v3.5" Depth="0" />
55 </RegistrySearch>
56 </Property>
57 </Fragment>
58
59 <!-- set to #1 if the .NET Framework 3.5 Chinese (Simplified) language pack is installed (not set otherwise) -->
60 <Fragment>
61 <Property Id="NETFRAMEWORK35_ZH_CN_LANGPACK" Secure="yes">
62 <RegistrySearch Id="NETFRAMEWORK35ZhCnLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.5\2052" Name="Install" Type="raw" />
63 </Property>
64 </Fragment>
65
66 <!-- set to #1 if the .NET Framework 3.5 Chinese (Traditional) language pack is installed (not set otherwise) -->
67 <Fragment>
68 <Property Id="NETFRAMEWORK35_ZH_TW_LANGPACK" Secure="yes">
69 <RegistrySearch Id="NETFRAMEWORK35ZhTwLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.5\1028" Name="Install" Type="raw" />
70 </Property>
71 </Fragment>
72
73 <!-- set to #1 if the .NET Framework 3.5 Czech language pack is installed (not set otherwise) -->
74 <Fragment>
75 <Property Id="NETFRAMEWORK35_CS_CZ_LANGPACK" Secure="yes">
76 <RegistrySearch Id="NETFRAMEWORK35CsCzLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.5\1029" Name="Install" Type="raw" />
77 </Property>
78 </Fragment>
79
80 <!-- set to #1 if the .NET Framework 3.5 Danish language pack is installed (not set otherwise) -->
81 <Fragment>
82 <Property Id="NETFRAMEWORK35_DA_DK_LANGPACK" Secure="yes">
83 <RegistrySearch Id="NETFRAMEWORK35DaDkLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.5\1030" Name="Install" Type="raw" />
84 </Property>
85 </Fragment>
86
87 <!-- set to #1 if the .NET Framework 3.5 Dutch language pack is installed (not set otherwise) -->
88 <Fragment>
89 <Property Id="NETFRAMEWORK35_NL_NL_LANGPACK" Secure="yes">
90 <RegistrySearch Id="NETFRAMEWORK35NlNlLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.5\1043" Name="Install" Type="raw" />
91 </Property>
92 </Fragment>
93
94 <!-- set to #1 if the .NET Framework 3.5 Finnish language pack is installed (not set otherwise) -->
95 <Fragment>
96 <Property Id="NETFRAMEWORK35_FI_FI_LANGPACK" Secure="yes">
97 <RegistrySearch Id="NETFRAMEWORK35FiFiLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.5\1035" Name="Install" Type="raw" />
98 </Property>
99 </Fragment>
100
101 <!-- set to #1 if the .NET Framework 3.5 French language pack is installed (not set otherwise) -->
102 <Fragment>
103 <Property Id="NETFRAMEWORK35_FR_FR_LANGPACK" Secure="yes">
104 <RegistrySearch Id="NETFRAMEWORK35FrFrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.5\1036" Name="Install" Type="raw" />
105 </Property>
106 </Fragment>
107
108 <!-- set to #1 if the .NET Framework 3.5 German language pack is installed (not set otherwise) -->
109 <Fragment>
110 <Property Id="NETFRAMEWORK35_DE_DE_LANGPACK" Secure="yes">
111 <RegistrySearch Id="NETFRAMEWORK35DeDeLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.5\1031" Name="Install" Type="raw" />
112 </Property>
113 </Fragment>
114
115 <!-- set to #1 if the .NET Framework 3.5 Greek language pack is installed (not set otherwise) -->
116 <Fragment>
117 <Property Id="NETFRAMEWORK35_EL_GR_LANGPACK" Secure="yes">
118 <RegistrySearch Id="NETFRAMEWORK35ElGrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.5\1032" Name="Install" Type="raw" />
119 </Property>
120 </Fragment>
121
122 <!-- set to #1 if the .NET Framework 3.5 Hungarian language pack is installed (not set otherwise) -->
123 <Fragment>
124 <Property Id="NETFRAMEWORK35_HU_HU_LANGPACK" Secure="yes">
125 <RegistrySearch Id="NETFRAMEWORK35HuHuLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.5\1038" Name="Install" Type="raw" />
126 </Property>
127 </Fragment>
128
129 <!-- set to #1 if the .NET Framework 3.5 Italian language pack is installed (not set otherwise) -->
130 <Fragment>
131 <Property Id="NETFRAMEWORK35_IT_IT_LANGPACK" Secure="yes">
132 <RegistrySearch Id="NETFRAMEWORK35ItItLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.5\1040" Name="Install" Type="raw" />
133 </Property>
134 </Fragment>
135
136 <!-- set to #1 if the .NET Framework 3.5 Japanese language pack is installed (not set otherwise) -->
137 <Fragment>
138 <Property Id="NETFRAMEWORK35_JA_JP_LANGPACK" Secure="yes">
139 <RegistrySearch Id="NETFRAMEWORK35JaJpLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.5\1041" Name="Install" Type="raw" />
140 </Property>
141 </Fragment>
142
143 <!-- set to #1 if the .NET Framework 3.5 Korean language pack is installed (not set otherwise) -->
144 <Fragment>
145 <Property Id="NETFRAMEWORK35_KO_KR_LANGPACK" Secure="yes">
146 <RegistrySearch Id="NETFRAMEWORK35KoKrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.5\1042" Name="Install" Type="raw" />
147 </Property>
148 </Fragment>
149
150 <!-- set to #1 if the .NET Framework 3.5 Norwegian language pack is installed (not set otherwise) -->
151 <Fragment>
152 <Property Id="NETFRAMEWORK35_NB_NO_LANGPACK" Secure="yes">
153 <RegistrySearch Id="NETFRAMEWORK35NbNoLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.5\1044" Name="Install" Type="raw" />
154 </Property>
155 </Fragment>
156
157 <!-- set to #1 if the .NET Framework 3.5 Polish language pack is installed (not set otherwise) -->
158 <Fragment>
159 <Property Id="NETFRAMEWORK35_PL_PL_LANGPACK" Secure="yes">
160 <RegistrySearch Id="NETFRAMEWORK35PlPlLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.5\1045" Name="Install" Type="raw" />
161 </Property>
162 </Fragment>
163
164 <!-- set to #1 if the .NET Framework 3.5 Portuguese (Brazil) language pack is installed (not set otherwise) -->
165 <Fragment>
166 <Property Id="NETFRAMEWORK35_PT_BR_LANGPACK" Secure="yes">
167 <RegistrySearch Id="NETFRAMEWORK35PtBrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.5\1046" Name="Install" Type="raw" />
168 </Property>
169 </Fragment>
170
171 <!-- set to #1 if the .NET Framework 3.5 Portuguese (Portugal) language pack is installed (not set otherwise) -->
172 <Fragment>
173 <Property Id="NETFRAMEWORK35_PT_PT_LANGPACK" Secure="yes">
174 <RegistrySearch Id="NETFRAMEWORK35PtPtLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.5\2070" Name="Install" Type="raw" />
175 </Property>
176 </Fragment>
177
178 <!-- set to #1 if the .NET Framework 3.5 Russian language pack is installed (not set otherwise) -->
179 <Fragment>
180 <Property Id="NETFRAMEWORK35_RU_RU_LANGPACK" Secure="yes">
181 <RegistrySearch Id="NETFRAMEWORK35RuRuLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.5\1049" Name="Install" Type="raw" />
182 </Property>
183 </Fragment>
184
185 <!-- set to #1 if the .NET Framework 3.5 Spanish language pack is installed (not set otherwise) -->
186 <Fragment>
187 <Property Id="NETFRAMEWORK35_ES_ES_LANGPACK" Secure="yes">
188 <RegistrySearch Id="NETFRAMEWORK35EsEsLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.5\3082" Name="Install" Type="raw" />
189 </Property>
190 </Fragment>
191
192 <!-- set to #1 if the .NET Framework 3.5 Swedish language pack is installed (not set otherwise) -->
193 <Fragment>
194 <Property Id="NETFRAMEWORK35_SV_SE_LANGPACK" Secure="yes">
195 <RegistrySearch Id="NETFRAMEWORK35SvSeLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.5\1053" Name="Install" Type="raw" />
196 </Property>
197 </Fragment>
198
199 <!-- set to #1 if the .NET Framework 3.5 Turkish language pack is installed (not set otherwise) -->
200 <Fragment>
201 <Property Id="NETFRAMEWORK35_TR_TR_LANGPACK" Secure="yes">
202 <RegistrySearch Id="NETFRAMEWORK35TrTrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.5\1055" Name="Install" Type="raw" />
203 </Property>
204 </Fragment>
205
206 <!-- set to #1 if the .NET Framework 3.5 client profile is installed (not set otherwise) -->
207 <Fragment>
208 <Property Id="NETFRAMEWORK35_CLIENT" Secure="yes">
209 <RegistrySearch Id="NETFRAMEWORK35ClientSearch" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\DotNetClient\v3.5" Name="Install" Type="raw" />
210 </Property>
211 </Fragment>
212
213 <!-- Indicates the service pack level for the .NET Framework 3.5 client profile -->
214 <Fragment>
215 <Property Id="NETFRAMEWORK35_CLIENT_SP_LEVEL" Secure="yes">
216 <RegistrySearch Id="NETFRAMEWORK35ClientSpSearch" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\DotNetClient\v3.5" Name="SP" Type="raw" />
217 </Property>
218 </Fragment>
219
220 <!-- location of the Windows SDK 6.0a installation root -->
221 <Fragment>
222 <Property Id="WINDOWSSDK60ADIR" Secure="yes">
223 <RegistrySearch Id="WindowsSdk60aDir" Root="HKLM" Key="Software\Microsoft\Microsoft SDKs\Windows\v6.0A" Name="InstallationFolder" Type="raw" />
224 </Property>
225 </Fragment>
226
227 <!-- location of the Windows SDK 6.1 installation root -->
228 <Fragment>
229 <Property Id="WINDOWSSDK61DIR" Secure="yes">
230 <RegistrySearch Id="WindowsSdk61Dir" Root="HKLM" Key="Software\Microsoft\Microsoft SDKs\Windows\v6.1" Name="InstallationFolder" Type="raw" />
231 </Property>
232 </Fragment>
233
234 <!-- location of the Windows SDK 7.0 installation root -->
235 <Fragment>
236 <Property Id="WINDOWSSDK70ADIR" Secure="yes">
237 <RegistrySearch Id="WindowsSdk70aDir" Root="HKLM" Key="Software\Microsoft\Microsoft SDKs\Windows\v7.0A" Name="InstallationFolder" Type="raw" />
238 </Property>
239 </Fragment>
240
241</Wix>
diff --git a/src/wixlib/NetFx3.wxs b/src/wixlib/NetFx3.wxs
new file mode 100644
index 00000000..12d51750
--- /dev/null
+++ b/src/wixlib/NetFx3.wxs
@@ -0,0 +1,195 @@
1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. -->
3
4
5<Wix xmlns="http://wixtoolset.org/schemas/v4/wxs">
6
7 <!--
8 .NET Framework installation state properties
9
10 Official documentation can be found at the following location:
11
12 .NET Framework 3.0 - http://msdn.microsoft.com/library/aa964979.aspx
13 -->
14
15 <!-- set to #1 if the .NET Framework 3.0 is installed (not set otherwise) -->
16 <Fragment>
17 <Property Id="NETFRAMEWORK30" Secure="yes">
18 <RegistrySearch Id="NetFramework30" Root="HKLM" Key="SOFTWARE\Microsoft\NET Framework Setup\NDP\v3.0\Setup" Name="InstallSuccess" Type="raw" />
19 </Property>
20 </Fragment>
21
22 <!-- Indicates the service pack level for the .NET Framework 3.0. -->
23 <!-- This value will not exist until a service pack is installed. -->
24 <Fragment>
25 <Property Id="NETFRAMEWORK30_SP_LEVEL" Secure="yes">
26 <RegistrySearch Id="NetFramework30SP" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.0" Name="SP" Type="raw" />
27 </Property>
28 </Fragment>
29
30 <!-- Location of .NET Framework 3.0 redistributable install root directory -->
31 <Fragment>
32 <Property Id="NETFRAMEWORK30INSTALLROOTDIR" Secure="yes">
33 <RegistrySearch Id="NetFxInstallRootForNetfx30Search" Type="raw" Root="HKLM" Key="Software\Microsoft\.NETFramework" Name="InstallRoot">
34 <DirectorySearch Id="NetFx30InstallRootSearch" Path="v3.0" Depth="0" />
35 </RegistrySearch>
36 </Property>
37 </Fragment>
38
39 <!-- Location of .NET Framework 3.0 (64-bit) redistributable install root directory -->
40 <Fragment>
41 <Property Id="NETFRAMEWORK30INSTALLROOTDIR64" Secure="yes">
42 <RegistrySearch Id="NetFxInstallRootForNetfx30Search64" Type="raw" Root="HKLM" Key="Software\Microsoft\.NETFramework" Name="InstallRoot" Win64="yes">
43 <DirectorySearch Id="NetFx30InstallRootSearch64" Path="v3.0" Depth="0" />
44 </RegistrySearch>
45 </Property>
46 </Fragment>
47
48 <!-- set to #1 if the .NET Framework 3.0 Chinese (Simplified) language pack is installed (not set otherwise) -->
49 <Fragment>
50 <Property Id="NETFRAMEWORK30_ZH_CN_LANGPACK" Secure="yes">
51 <RegistrySearch Id="NETFRAMEWORK30ZhCnLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.0\Setup\2052" Name="Install" Type="raw" />
52 </Property>
53 </Fragment>
54
55 <!-- set to #1 if the .NET Framework 3.0 Chinese (Traditional) language pack is installed (not set otherwise) -->
56 <Fragment>
57 <Property Id="NETFRAMEWORK30_ZH_TW_LANGPACK" Secure="yes">
58 <RegistrySearch Id="NETFRAMEWORK30ZhTwLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.0\Setup\1028" Name="Install" Type="raw" />
59 </Property>
60 </Fragment>
61
62 <!-- set to #1 if the .NET Framework 3.0 Czech language pack is installed (not set otherwise) -->
63 <Fragment>
64 <Property Id="NETFRAMEWORK30_CS_CZ_LANGPACK" Secure="yes">
65 <RegistrySearch Id="NETFRAMEWORK30CsCzLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.0\Setup\1029" Name="Install" Type="raw" />
66 </Property>
67 </Fragment>
68
69 <!-- set to #1 if the .NET Framework 3.0 Danish language pack is installed (not set otherwise) -->
70 <Fragment>
71 <Property Id="NETFRAMEWORK30_DA_DK_LANGPACK" Secure="yes">
72 <RegistrySearch Id="NETFRAMEWORK30DaDkLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.0\Setup\1030" Name="Install" Type="raw" />
73 </Property>
74 </Fragment>
75
76 <!-- set to #1 if the .NET Framework 3.0 Dutch language pack is installed (not set otherwise) -->
77 <Fragment>
78 <Property Id="NETFRAMEWORK30_NL_NL_LANGPACK" Secure="yes">
79 <RegistrySearch Id="NETFRAMEWORK30NlNlLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.0\Setup\1043" Name="Install" Type="raw" />
80 </Property>
81 </Fragment>
82
83 <!-- set to #1 if the .NET Framework 3.0 Finnish language pack is installed (not set otherwise) -->
84 <Fragment>
85 <Property Id="NETFRAMEWORK30_FI_FI_LANGPACK" Secure="yes">
86 <RegistrySearch Id="NETFRAMEWORK30FiFiLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.0\Setup\1035" Name="Install" Type="raw" />
87 </Property>
88 </Fragment>
89
90 <!-- set to #1 if the .NET Framework 3.0 French language pack is installed (not set otherwise) -->
91 <Fragment>
92 <Property Id="NETFRAMEWORK30_FR_FR_LANGPACK" Secure="yes">
93 <RegistrySearch Id="NETFRAMEWORK30FrFrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.0\Setup\1036" Name="Install" Type="raw" />
94 </Property>
95 </Fragment>
96
97 <!-- set to #1 if the .NET Framework 3.0 German language pack is installed (not set otherwise) -->
98 <Fragment>
99 <Property Id="NETFRAMEWORK30_DE_DE_LANGPACK" Secure="yes">
100 <RegistrySearch Id="NETFRAMEWORK30DeDeLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.0\Setup\1031" Name="Install" Type="raw" />
101 </Property>
102 </Fragment>
103
104 <!-- set to #1 if the .NET Framework 3.0 Greek language pack is installed (not set otherwise) -->
105 <Fragment>
106 <Property Id="NETFRAMEWORK30_EL_GR_LANGPACK" Secure="yes">
107 <RegistrySearch Id="NETFRAMEWORK30ElGrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.0\Setup\1032" Name="Install" Type="raw" />
108 </Property>
109 </Fragment>
110
111 <!-- set to #1 if the .NET Framework 3.0 Hungarian language pack is installed (not set otherwise) -->
112 <Fragment>
113 <Property Id="NETFRAMEWORK30_HU_HU_LANGPACK" Secure="yes">
114 <RegistrySearch Id="NETFRAMEWORK30HuHuLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.0\Setup\1038" Name="Install" Type="raw" />
115 </Property>
116 </Fragment>
117
118 <!-- set to #1 if the .NET Framework 3.0 Italian language pack is installed (not set otherwise) -->
119 <Fragment>
120 <Property Id="NETFRAMEWORK30_IT_IT_LANGPACK" Secure="yes">
121 <RegistrySearch Id="NETFRAMEWORK30ItItLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.0\Setup\1040" Name="Install" Type="raw" />
122 </Property>
123 </Fragment>
124
125 <!-- set to #1 if the .NET Framework 3.0 Japanese language pack is installed (not set otherwise) -->
126 <Fragment>
127 <Property Id="NETFRAMEWORK30_JA_JP_LANGPACK" Secure="yes">
128 <RegistrySearch Id="NETFRAMEWORK30JaJpLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.0\Setup\1041" Name="Install" Type="raw" />
129 </Property>
130 </Fragment>
131
132 <!-- set to #1 if the .NET Framework 3.0 Korean language pack is installed (not set otherwise) -->
133 <Fragment>
134 <Property Id="NETFRAMEWORK30_KO_KR_LANGPACK" Secure="yes">
135 <RegistrySearch Id="NETFRAMEWORK30KoKrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.0\Setup\1042" Name="Install" Type="raw" />
136 </Property>
137 </Fragment>
138
139 <!-- set to #1 if the .NET Framework 3.0 Norwegian language pack is installed (not set otherwise) -->
140 <Fragment>
141 <Property Id="NETFRAMEWORK30_NB_NO_LANGPACK" Secure="yes">
142 <RegistrySearch Id="NETFRAMEWORK30NbNoLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.0\Setup\1044" Name="Install" Type="raw" />
143 </Property>
144 </Fragment>
145
146 <!-- set to #1 if the .NET Framework 3.0 Polish language pack is installed (not set otherwise) -->
147 <Fragment>
148 <Property Id="NETFRAMEWORK30_PL_PL_LANGPACK" Secure="yes">
149 <RegistrySearch Id="NETFRAMEWORK30PlPlLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.0\Setup\1045" Name="Install" Type="raw" />
150 </Property>
151 </Fragment>
152
153 <!-- set to #1 if the .NET Framework 3.0 Portuguese (Brazil) language pack is installed (not set otherwise) -->
154 <Fragment>
155 <Property Id="NETFRAMEWORK30_PT_BR_LANGPACK" Secure="yes">
156 <RegistrySearch Id="NETFRAMEWORK30PtBrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.0\Setup\1046" Name="Install" Type="raw" />
157 </Property>
158 </Fragment>
159
160 <!-- set to #1 if the .NET Framework 3.0 Portuguese (Portugal) language pack is installed (not set otherwise) -->
161 <Fragment>
162 <Property Id="NETFRAMEWORK30_PT_PT_LANGPACK" Secure="yes">
163 <RegistrySearch Id="NETFRAMEWORK30PtPtLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.0\Setup\2070" Name="Install" Type="raw" />
164 </Property>
165 </Fragment>
166
167 <!-- set to #1 if the .NET Framework 3.0 Russian language pack is installed (not set otherwise) -->
168 <Fragment>
169 <Property Id="NETFRAMEWORK30_RU_RU_LANGPACK" Secure="yes">
170 <RegistrySearch Id="NETFRAMEWORK30RuRuLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.0\Setup\1049" Name="Install" Type="raw" />
171 </Property>
172 </Fragment>
173
174 <!-- set to #1 if the .NET Framework 3.0 Spanish language pack is installed (not set otherwise) -->
175 <Fragment>
176 <Property Id="NETFRAMEWORK30_ES_ES_LANGPACK" Secure="yes">
177 <RegistrySearch Id="NETFRAMEWORK30EsEsLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.0\Setup\3082" Name="Install" Type="raw" />
178 </Property>
179 </Fragment>
180
181 <!-- set to #1 if the .NET Framework 3.0 Swedish language pack is installed (not set otherwise) -->
182 <Fragment>
183 <Property Id="NETFRAMEWORK30_SV_SE_LANGPACK" Secure="yes">
184 <RegistrySearch Id="NETFRAMEWORK30SvSeLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.0\Setup\1053" Name="Install" Type="raw" />
185 </Property>
186 </Fragment>
187
188 <!-- set to #1 if the .NET Framework 3.0 Turkish language pack is installed (not set otherwise) -->
189 <Fragment>
190 <Property Id="NETFRAMEWORK30_TR_TR_LANGPACK" Secure="yes">
191 <RegistrySearch Id="NETFRAMEWORK30TrTrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v3.0\Setup\1055" Name="Install" Type="raw" />
192 </Property>
193 </Fragment>
194
195</Wix>
diff --git a/src/wixlib/NetFx4.5.wxs b/src/wixlib/NetFx4.5.wxs
new file mode 100644
index 00000000..f2ddd051
--- /dev/null
+++ b/src/wixlib/NetFx4.5.wxs
@@ -0,0 +1,274 @@
1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. -->
3
4
5<Wix xmlns="http://wixtoolset.org/schemas/v4/wxs" xmlns:util="http://wixtoolset.org/schemas/v4/wxs/util">
6
7 <!--
8 .NET Framework installation state properties
9
10 Official documentation can be found at the following location:
11
12 .NET Framework 4.5 - http://msdn.microsoft.com/en-us/library/5a4x27ek.aspx, http://msdn.microsoft.com/en-us/library/ee942965(v=VS.110).aspx
13 -->
14
15 <?define NetFx45MinRelease = 378389?>
16 <?define NetFx45WebLink = http://go.microsoft.com/fwlink/?LinkId=225704 ?>
17 <?define NetFx45RedistLink = http://go.microsoft.com/fwlink/?LinkId=225702 ?>
18
19 <Fragment>
20 <PropertyRef Id="WIXNETFX4RELEASEINSTALLED" />
21 <Property Id="WIX_IS_NETFRAMEWORK_45_OR_LATER_INSTALLED" Secure="yes" />
22 <SetProperty Id="WIX_IS_NETFRAMEWORK_45_OR_LATER_INSTALLED" Value="1" After="AppSearch">
23 WIXNETFX4RELEASEINSTALLED >= "#$(var.NetFx45MinRelease)"
24 </SetProperty>
25 </Fragment>
26
27 <Fragment>
28 <util:RegistrySearch
29 Id="NETFRAMEWORK45"
30 Variable="NETFRAMEWORK45"
31 Root="HKLM"
32 Key="SOFTWARE\Microsoft\NET Framework Setup\NDP\v4\Full"
33 Value="Release"
34 Result="value" />
35 </Fragment>
36
37 <Fragment>
38 <util:RegistrySearchRef Id="NETFRAMEWORK45"/>
39
40 <WixVariable Id="NetFx45WebDetectCondition" Value="NETFRAMEWORK45 &gt;= $(var.NetFx45MinRelease)" Overridable="yes" />
41 <WixVariable Id="NetFx45WebInstallCondition" Value="" Overridable="yes" />
42 <WixVariable Id="NetFx45WebPackageDirectory" Value="redist\" Overridable="yes" />
43
44 <PackageGroup Id="NetFx45Web">
45 <ExePackage
46 InstallCommand="/q /norestart /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx45FullWebLog].html&quot;"
47 RepairCommand="/q /norestart /repair /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx45FullWebLog].html&quot;"
48 UninstallCommand="/uninstall /q /norestart /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx45FullWebLog].html&quot;"
49 PerMachine="yes"
50 DetectCondition="!(wix.NetFx45WebDetectCondition)"
51 InstallCondition="!(wix.NetFx45WebInstallCondition)"
52 Id="NetFx45Web"
53 Vital="yes"
54 Permanent="yes"
55 Protocol="netfx4"
56 DownloadUrl="$(var.NetFx45WebLink)"
57 LogPathVariable="NetFx45FullWebLog"
58 Compressed="no"
59 Name="!(wix.NetFx45WebPackageDirectory)dotNetFx45_Full_setup.exe">
60 <RemotePayload
61 Size="1005568"
62 Version="4.5.50709.17929"
63 ProductName="Microsoft .NET Framework 4.5"
64 Description="Microsoft .NET Framework 4.5 Setup"
65 CertificatePublicKey="BE931A1B869E4BB989C2B32D0C105204ECBEFB3D"
66 CertificateThumbprint="8363887511B4835B79C383ECF06FC055B5839255"
67 Hash="F6BA6F03C65C3996A258F58324A917463B2D6FF4"/>
68 </ExePackage>
69 </PackageGroup>
70 </Fragment>
71
72 <Fragment>
73 <util:RegistrySearchRef Id="NETFRAMEWORK45"/>
74
75 <WixVariable Id="NetFx45RedistDetectCondition" Value="NETFRAMEWORK45 &gt;= $(var.NetFx45MinRelease)" Overridable="yes" />
76 <WixVariable Id="NetFx45RedistInstallCondition" Value="" Overridable="yes" />
77 <WixVariable Id="NetFx45RedistPackageDirectory" Value="redist\" Overridable="yes" />
78
79 <PackageGroup Id="NetFx45Redist">
80 <ExePackage
81 InstallCommand="/q /norestart /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx45FullLog].html&quot;"
82 RepairCommand="/q /norestart /repair /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx45FullLog].html&quot;"
83 UninstallCommand="/uninstall /q /norestart /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx45FullLog].html&quot;"
84 PerMachine="yes"
85 DetectCondition="!(wix.NetFx45RedistDetectCondition)"
86 InstallCondition="!(wix.NetFx45RedistInstallCondition)"
87 Id="NetFx45Redist"
88 Vital="yes"
89 Permanent="yes"
90 Protocol="netfx4"
91 DownloadUrl="$(var.NetFx45RedistLink)"
92 LogPathVariable="NetFx45FullLog"
93 Compressed="no"
94 Name="!(wix.NetFx45RedistPackageDirectory)dotNetFx45_Full_x86_x64.exe">
95 <RemotePayload
96 Size="50352408"
97 Version="4.5.50709.17929"
98 ProductName="Microsoft .NET Framework 4.5"
99 Description="Microsoft .NET Framework 4.5 Setup"
100 CertificatePublicKey="BE931A1B869E4BB989C2B32D0C105204ECBEFB3D"
101 CertificateThumbprint="8363887511B4835B79C383ECF06FC055B5839255"
102 Hash="B2FF712CA0947040CA0B8E9BD7436A3C3524BB5D"/>
103 </ExePackage>
104 </PackageGroup>
105 </Fragment>
106
107 <!-- set to Release number of the .NET Framework 4.5 if installed (not set otherwise) -->
108 <Fragment>
109 <Property Id="NETFRAMEWORK45" Secure="yes">
110 <RegistrySearch Id="NetFramework45" Root="HKLM" Key="SOFTWARE\Microsoft\NET Framework Setup\NDP\v4\Full" Name="Release" Type="raw" />
111 </Property>
112 </Fragment>
113
114 <!-- set to Release number of the .NET Framework 4.5 Arabic language pack if installed (not set otherwise) -->
115 <Fragment>
116 <Property Id="NETFRAMEWORK45_AR_SA_LANGPACK" Secure="yes">
117 <RegistrySearch Id="NETFRAMEWORK45ArSaLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1025" Name="Release" Type="raw" />
118 </Property>
119 </Fragment>
120
121 <!-- set to Release number of the .NET Framework 4.5 Chinese (Simplified) language pack if installed (not set otherwise) -->
122 <Fragment>
123 <Property Id="NETFRAMEWORK45_ZH_CN_LANGPACK" Secure="yes">
124 <RegistrySearch Id="NETFRAMEWORK45ZhCnLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\2052" Name="Release" Type="raw" />
125 </Property>
126 </Fragment>
127
128 <!-- set to Release number of the .NET Framework 4.5 Chinese (Traditional) language pack if installed (not set otherwise) -->
129 <Fragment>
130 <Property Id="NETFRAMEWORK45_ZH_TW_LANGPACK" Secure="yes">
131 <RegistrySearch Id="NETFRAMEWORK45ZhTwLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1028" Name="Release" Type="raw" />
132 </Property>
133 </Fragment>
134
135 <!-- set to Release number of the .NET Framework 4.5 Czech language pack if installed (not set otherwise) -->
136 <Fragment>
137 <Property Id="NETFRAMEWORK45_CS_CZ_LANGPACK" Secure="yes">
138 <RegistrySearch Id="NETFRAMEWORK45CsCzLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1029" Name="Release" Type="raw" />
139 </Property>
140 </Fragment>
141
142 <!-- set to Release number of the .NET Framework 4.5 Danish language pack if installed (not set otherwise) -->
143 <Fragment>
144 <Property Id="NETFRAMEWORK45_DA_DK_LANGPACK" Secure="yes">
145 <RegistrySearch Id="NETFRAMEWORK45DaDkLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1030" Name="Release" Type="raw" />
146 </Property>
147 </Fragment>
148
149 <!-- set to Release number of the .NET Framework 4.5 Dutch language pack if installed (not set otherwise) -->
150 <Fragment>
151 <Property Id="NETFRAMEWORK45_NL_NL_LANGPACK" Secure="yes">
152 <RegistrySearch Id="NETFRAMEWORK45NlNlLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1043" Name="Release" Type="raw" />
153 </Property>
154 </Fragment>
155
156 <!-- set to Release number of the .NET Framework 4.5 Finnish language pack if installed (not set otherwise) -->
157 <Fragment>
158 <Property Id="NETFRAMEWORK45_FI_FI_LANGPACK" Secure="yes">
159 <RegistrySearch Id="NETFRAMEWORK45FiFiLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1035" Name="Release" Type="raw" />
160 </Property>
161 </Fragment>
162
163 <!-- set to Release number of the .NET Framework 4.5 French language pack if installed (not set otherwise) -->
164 <Fragment>
165 <Property Id="NETFRAMEWORK45_FR_FR_LANGPACK" Secure="yes">
166 <RegistrySearch Id="NETFRAMEWORK45FrFrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1036" Name="Release" Type="raw" />
167 </Property>
168 </Fragment>
169
170 <!-- set to Release number of the .NET Framework 4.5 German language pack if installed (not set otherwise) -->
171 <Fragment>
172 <Property Id="NETFRAMEWORK45_DE_DE_LANGPACK" Secure="yes">
173 <RegistrySearch Id="NETFRAMEWORK45DeDeLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1031" Name="Release" Type="raw" />
174 </Property>
175 </Fragment>
176
177 <!-- set to Release number of the .NET Framework 4.5 Greek language pack if installed (not set otherwise) -->
178 <Fragment>
179 <Property Id="NETFRAMEWORK45_EL_GR_LANGPACK" Secure="yes">
180 <RegistrySearch Id="NETFRAMEWORK45ElGrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1032" Name="Release" Type="raw" />
181 </Property>
182 </Fragment>
183
184 <!-- set to Release number of the .NET Framework 4.5 Hebrew language pack if installed (not set otherwise) -->
185 <Fragment>
186 <Property Id="NETFRAMEWORK45_HE_IL_LANGPACK" Secure="yes">
187 <RegistrySearch Id="NETFRAMEWORK45HeIlLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1037" Name="Release" Type="raw" />
188 </Property>
189 </Fragment>
190
191 <!-- set to Release number of the .NET Framework 4.5 Hungarian language pack if installed (not set otherwise) -->
192 <Fragment>
193 <Property Id="NETFRAMEWORK45_HU_HU_LANGPACK" Secure="yes">
194 <RegistrySearch Id="NETFRAMEWORK45HuHuLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1038" Name="Release" Type="raw" />
195 </Property>
196 </Fragment>
197
198 <!-- set to Release number of the .NET Framework 4.5 Italian language pack if installed (not set otherwise) -->
199 <Fragment>
200 <Property Id="NETFRAMEWORK45_IT_IT_LANGPACK" Secure="yes">
201 <RegistrySearch Id="NETFRAMEWORK45ItItLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1040" Name="Release" Type="raw" />
202 </Property>
203 </Fragment>
204
205 <!-- set to Release number of the .NET Framework 4.5 Japanese language pack if installed (not set otherwise) -->
206 <Fragment>
207 <Property Id="NETFRAMEWORK45_JA_JP_LANGPACK" Secure="yes">
208 <RegistrySearch Id="NETFRAMEWORK45JaJpLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1041" Name="Release" Type="raw" />
209 </Property>
210 </Fragment>
211
212 <!-- set to Release number of the .NET Framework 4.5 Korean language pack if installed (not set otherwise) -->
213 <Fragment>
214 <Property Id="NETFRAMEWORK45_KO_KR_LANGPACK" Secure="yes">
215 <RegistrySearch Id="NETFRAMEWORK45KoKrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1042" Name="Release" Type="raw" />
216 </Property>
217 </Fragment>
218
219 <!-- set to Release number of the .NET Framework 4.5 Norwegian language pack if installed (not set otherwise) -->
220 <Fragment>
221 <Property Id="NETFRAMEWORK45_NB_NO_LANGPACK" Secure="yes">
222 <RegistrySearch Id="NETFRAMEWORK45NbNoLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1044" Name="Release" Type="raw" />
223 </Property>
224 </Fragment>
225
226 <!-- set to Release number of the .NET Framework 4.5 Polish language pack if installed (not set otherwise) -->
227 <Fragment>
228 <Property Id="NETFRAMEWORK45_PL_PL_LANGPACK" Secure="yes">
229 <RegistrySearch Id="NETFRAMEWORK45PlPlLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1045" Name="Release" Type="raw" />
230 </Property>
231 </Fragment>
232
233 <!-- set to Release number of the .NET Framework 4.5 Portuguese (Brazil) language pack if installed (not set otherwise) -->
234 <Fragment>
235 <Property Id="NETFRAMEWORK45_PT_BR_LANGPACK" Secure="yes">
236 <RegistrySearch Id="NETFRAMEWORK45PtBrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1046" Name="Release" Type="raw" />
237 </Property>
238 </Fragment>
239
240 <!-- set to Release number of the .NET Framework 4.5 Portuguese (Portugal) language pack if installed (not set otherwise) -->
241 <Fragment>
242 <Property Id="NETFRAMEWORK45_PT_PT_LANGPACK" Secure="yes">
243 <RegistrySearch Id="NETFRAMEWORK45PtPtLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\2070" Name="Release" Type="raw" />
244 </Property>
245 </Fragment>
246
247 <!-- set to Release number of the .NET Framework 4.5 Russian language pack if installed (not set otherwise) -->
248 <Fragment>
249 <Property Id="NETFRAMEWORK45_RU_RU_LANGPACK" Secure="yes">
250 <RegistrySearch Id="NETFRAMEWORK45RuRuLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1049" Name="Release" Type="raw" />
251 </Property>
252 </Fragment>
253
254 <!-- set to Release number of the .NET Framework 4.5 Spanish language pack if installed (not set otherwise) -->
255 <Fragment>
256 <Property Id="NETFRAMEWORK45_ES_ES_LANGPACK" Secure="yes">
257 <RegistrySearch Id="NETFRAMEWORK45EsEsLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\3082" Name="Release" Type="raw" />
258 </Property>
259 </Fragment>
260
261 <!-- set to Release number of the .NET Framework 4.5 Swedish language pack if installed (not set otherwise) -->
262 <Fragment>
263 <Property Id="NETFRAMEWORK45_SV_SE_LANGPACK" Secure="yes">
264 <RegistrySearch Id="NETFRAMEWORK45SvSeLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1053" Name="Release" Type="raw" />
265 </Property>
266 </Fragment>
267
268 <!-- set to Release number of the .NET Framework 4.5 Turkish language pack if installed (not set otherwise) -->
269 <Fragment>
270 <Property Id="NETFRAMEWORK45_TR_TR_LANGPACK" Secure="yes">
271 <RegistrySearch Id="NETFRAMEWORK45TrTrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1055" Name="Release" Type="raw" />
272 </Property>
273 </Fragment>
274</Wix>
diff --git a/src/wixlib/NetFx4.wxs b/src/wixlib/NetFx4.wxs
new file mode 100644
index 00000000..fa26435f
--- /dev/null
+++ b/src/wixlib/NetFx4.wxs
@@ -0,0 +1,543 @@
1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. -->
3
4
5<Wix xmlns="http://wixtoolset.org/schemas/v4/wxs" xmlns:util="http://wixtoolset.org/schemas/v4/wxs/util">
6
7 <!--
8 .NET Framework installation state properties
9
10 Official documentation can be found at the following location:
11
12 .NET Framework 4.0 full & client - http://msdn.microsoft.com/en-us/library/ee942965.aspx
13 -->
14
15 <?define NetFx40WebLink = http://go.microsoft.com/fwlink/?linkid=182805 ?>
16 <?define NetFx40RedistLink = http://go.microsoft.com/fwlink/?LinkId=247729 ?>
17 <?define NetFx40ClientWebLink = http://go.microsoft.com/fwlink/?linkid=182804 ?>
18 <?define NetFx40ClientRedistLink = http://go.microsoft.com/fwlink/?LinkId=247730 ?>
19
20 <Fragment>
21 <PropertyRef Id="NETFRAMEWORK40FULL" />
22 <Property Id="WIX_IS_NETFRAMEWORK_40_OR_LATER_INSTALLED" Secure="yes" />
23 <SetProperty Id="WIX_IS_NETFRAMEWORK_40_OR_LATER_INSTALLED" Value="1" After="AppSearch">
24 NETFRAMEWORK40FULL
25 </SetProperty>
26 </Fragment>
27
28 <Fragment>
29 <util:RegistrySearch
30 Id="NETFRAMEWORK40"
31 Variable="NETFRAMEWORK40"
32 Root="HKLM"
33 Key="SOFTWARE\Microsoft\NET Framework Setup\NDP\v4\Full"
34 Value="Install"
35 Result="value" />
36 </Fragment>
37
38 <Fragment>
39 <util:RegistrySearchRef Id="NETFRAMEWORK40"/>
40
41 <PackageGroup Id="NetFx40Web">
42 <ExePackage
43 InstallCommand="/q /norestart /ChainingPackage &quot;[WixBundleName]&quot;"
44 RepairCommand="/q /norestart /repair /ChainingPackage &quot;[WixBundleName]&quot;"
45 UninstallCommand="/uninstall /q /norestart /ChainingPackage &quot;[WixBundleName]&quot;"
46 PerMachine="yes"
47 DetectCondition="NETFRAMEWORK40"
48 Id="NetFx40Web"
49 Vital="yes"
50 Permanent="yes"
51 Protocol="netfx4"
52 DownloadUrl="$(var.NetFx40WebLink)"
53 Compressed="no"
54 Name="redist\dotNetFx40_Full_setup.exe">
55 <RemotePayload
56 Size="889416"
57 Version="4.0.30319.1"
58 ProductName="Microsoft .NET Framework 4"
59 Description="Microsoft .NET Framework 4 Setup"
60 CertificatePublicKey="672605E36DD71EC6B8325B91C5FE6971390CB6B6"
61 CertificateThumbprint="9617094A1CFB59AE7C1F7DFDB6739E4E7C40508F"
62 Hash="06BECADB92A5FCCA2529C0B93687C2A0C6D0D610"/>
63 </ExePackage>
64 </PackageGroup>
65 </Fragment>
66
67 <Fragment>
68 <util:RegistrySearchRef Id="NETFRAMEWORK40"/>
69
70 <PackageGroup Id="NetFx40Redist">
71 <ExePackage
72 InstallCommand="/q /norestart /ChainingPackage &quot;[WixBundleName]&quot;"
73 RepairCommand="/q /norestart /repair /ChainingPackage &quot;[WixBundleName]&quot;"
74 UninstallCommand="/uninstall /q /norestart /ChainingPackage &quot;[WixBundleName]&quot;"
75 PerMachine="yes"
76 DetectCondition="NETFRAMEWORK40"
77 Id="NetFx40Redist"
78 Vital="yes"
79 Permanent="yes"
80 Protocol="netfx4"
81 DownloadUrl="$(var.NetFx40RedistLink)"
82 Compressed="no"
83 Name="redist\dotNetFx40_Full_x86_x64.exe">
84 <RemotePayload
85 Size="50449456"
86 Version="4.0.30319.1"
87 ProductName="Microsoft .NET Framework 4"
88 Description="Microsoft .NET Framework 4 Setup"
89 CertificatePublicKey="672605E36DD71EC6B8325B91C5FE6971390CB6B6"
90 CertificateThumbprint="9617094A1CFB59AE7C1F7DFDB6739E4E7C40508F"
91 Hash="58DA3D74DB353AAD03588CBB5CEA8234166D8B99"/>
92 </ExePackage>
93 </PackageGroup>
94 </Fragment>
95
96 <Fragment>
97 <util:RegistrySearch
98 Id="NETFRAMEWORK40CLIENT"
99 Variable="NETFRAMEWORK40CLIENT"
100 Root="HKLM"
101 Key="SOFTWARE\Microsoft\NET Framework Setup\NDP\v4\Client"
102 Value="Install"
103 Result="value" />
104 </Fragment>
105
106
107 <Fragment>
108 <util:RegistrySearchRef Id="NETFRAMEWORK40CLIENT"/>
109
110 <PackageGroup Id="NetFx40ClientWeb">
111 <ExePackage
112 InstallCommand="/q /norestart /ChainingPackage &quot;[WixBundleName]&quot;"
113 RepairCommand="/q /norestart /repair /ChainingPackage &quot;[WixBundleName]&quot;"
114 UninstallCommand="/uninstall /q /norestart /ChainingPackage &quot;[WixBundleName]&quot;"
115 PerMachine="yes"
116 DetectCondition="NETFRAMEWORK40CLIENT"
117 Id="NetFx40ClientWeb"
118 Vital="yes"
119 Permanent="yes"
120 Protocol="netfx4"
121 DownloadUrl="$(var.NetFx40ClientWebLink)"
122 Compressed="no"
123 Name="redist\dotNetFx40_Client_setup.exe">
124 <RemotePayload
125 Size="887896"
126 Version="4.0.30319.1"
127 ProductName="Microsoft .NET Framework 4 Client Profile"
128 Description="Microsoft .NET Framework 4 Client Profile Setup"
129 CertificatePublicKey="672605E36DD71EC6B8325B91C5FE6971390CB6B6"
130 CertificateThumbprint="9617094A1CFB59AE7C1F7DFDB6739E4E7C40508F"
131 Hash="E15AD80FC74277EF2048312E9A71AF56B2EBA622"/>
132 </ExePackage>
133 </PackageGroup>
134 </Fragment>
135
136 <Fragment>
137 <util:RegistrySearchRef Id="NETFRAMEWORK40CLIENT"/>
138
139 <PackageGroup Id="NetFx40ClientRedist">
140 <ExePackage
141 InstallCommand="/q /norestart /ChainingPackage &quot;[WixBundleName]&quot;"
142 RepairCommand="/q /norestart /repair /ChainingPackage &quot;[WixBundleName]&quot;"
143 UninstallCommand="/uninstall /q /norestart /ChainingPackage &quot;[WixBundleName]&quot;"
144 PerMachine="yes"
145 DetectCondition="NETFRAMEWORK40CLIENT"
146 Id="NetFx40ClientRedist"
147 Vital="yes"
148 Permanent="yes"
149 Protocol="netfx4"
150 DownloadUrl="$(var.NetFx40ClientRedistLink)"
151 Compressed="no"
152 Name="redist\dotNetFx40_Client_x86_x64.exe">
153 <RemotePayload
154 Size="43000680"
155 Version="4.0.30319.1"
156 ProductName="Microsoft .NET Framework 4 Client Profile"
157 Description="Microsoft .NET Framework 4 Client Profile Setup"
158 CertificatePublicKey="672605E36DD71EC6B8325B91C5FE6971390CB6B6"
159 CertificateThumbprint="9617094A1CFB59AE7C1F7DFDB6739E4E7C40508F"
160 Hash="4CD67F609F89D617D2B206341B8C211E1B88B287"/>
161 </ExePackage>
162 </PackageGroup>
163 </Fragment>
164
165 <!-- set to #1 if the .NET Framework 4.0 client is installed (not set otherwise) -->
166 <Fragment>
167 <Property Id="NETFRAMEWORK40CLIENT" Secure="yes">
168 <RegistrySearch Id="NetFramework40Client" Root="HKLM" Key="SOFTWARE\Microsoft\NET Framework Setup\NDP\v4\Client" Name="Install" Type="raw" />
169 </Property>
170 </Fragment>
171
172 <!-- Indicates the servicing level for the .NET Framework 4.0 client. -->
173 <Fragment>
174 <Property Id="NETFRAMEWORK40CLIENT_SERVICING_LEVEL" Secure="yes">
175 <RegistrySearch Id="NetFramework40ClientServicing" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Client" Name="Servicing" Type="raw" />
176 </Property>
177 </Fragment>
178
179 <!-- Location of .NET Framework 4.0 client redistributable install root directory -->
180 <Fragment>
181 <Property Id="NETFRAMEWORK40CLIENTINSTALLROOTDIR" Secure="yes">
182 <RegistrySearch Id="NetFxInstallRootForNetfx40Client" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Client" Name="InstallPath" Type="raw" />
183 </Property>
184 </Fragment>
185
186 <!-- Location of .NET Framework 4.0 client (64-bit) redistributable install root directory -->
187 <Fragment>
188 <Property Id="NETFRAMEWORK40CLIENTINSTALLROOTDIR64" Secure="yes">
189 <RegistrySearch Id="NetFxInstallRootForNetfx40Client64" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Client" Name="InstallPath" Type="raw" Win64="yes" />
190 </Property>
191 </Fragment>
192
193 <!-- set to #1 if the .NET Framework 4.0 full is installed (not set otherwise) -->
194 <Fragment>
195 <Property Id="NETFRAMEWORK40FULL" Secure="yes">
196 <RegistrySearch Id="NetFramework40Full" Root="HKLM" Key="SOFTWARE\Microsoft\NET Framework Setup\NDP\v4\Full" Name="Install" Type="raw" />
197 </Property>
198 </Fragment>
199
200 <!-- Indicates the servicing level for the .NET Framework 4.0 full. -->
201 <Fragment>
202 <Property Id="NETFRAMEWORK40FULL_SERVICING_LEVEL" Secure="yes">
203 <RegistrySearch Id="NetFramework40FullServicing" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full" Name="Servicing" Type="raw" />
204 </Property>
205 </Fragment>
206
207 <!-- Location of .NET Framework 4.0 full redistributable install root directory -->
208 <Fragment>
209 <Property Id="NETFRAMEWORK40FULLINSTALLROOTDIR" Secure="yes">
210 <RegistrySearch Id="NetFxInstallRootForNetfx40Full" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full" Name="InstallPath" Type="raw" />
211 </Property>
212 </Fragment>
213
214 <!-- Location of .NET Framework 4.0 full (64-bit) redistributable install root directory -->
215 <Fragment>
216 <Property Id="NETFRAMEWORK40FULLINSTALLROOTDIR64" Secure="yes">
217 <RegistrySearch Id="NetFxInstallRootForNetfx40Full64" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full" Name="InstallPath" Type="raw" Win64="yes" />
218 </Property>
219 </Fragment>
220
221 <!-- set to #1 if the .NET Framework 4.0 Client Arabic language pack is installed (not set otherwise) -->
222 <Fragment>
223 <Property Id="NETFRAMEWORK40CLIENT_AR_SA_LANGPACK" Secure="yes">
224 <RegistrySearch Id="NETFRAMEWORK40CLIENTArSaLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Client\1025" Name="Install" Type="raw" />
225 </Property>
226 </Fragment>
227
228 <!-- set to #1 if the .NET Framework 4.0 Client Chinese (Simplified) language pack is installed (not set otherwise) -->
229 <Fragment>
230 <Property Id="NETFRAMEWORK40CLIENT_ZH_CN_LANGPACK" Secure="yes">
231 <RegistrySearch Id="NETFRAMEWORK40CLIENTZhCnLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Client\2052" Name="Install" Type="raw" />
232 </Property>
233 </Fragment>
234
235 <!-- set to #1 if the .NET Framework 4.0 Client Chinese (Traditional) language pack is installed (not set otherwise) -->
236 <Fragment>
237 <Property Id="NETFRAMEWORK40CLIENT_ZH_TW_LANGPACK" Secure="yes">
238 <RegistrySearch Id="NETFRAMEWORK40CLIENTZhTwLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Client\1028" Name="Install" Type="raw" />
239 </Property>
240 </Fragment>
241
242 <!-- set to #1 if the .NET Framework 4.0 Client Czech language pack is installed (not set otherwise) -->
243 <Fragment>
244 <Property Id="NETFRAMEWORK40CLIENT_CS_CZ_LANGPACK" Secure="yes">
245 <RegistrySearch Id="NETFRAMEWORK40CLIENTCsCzLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Client\1029" Name="Install" Type="raw" />
246 </Property>
247 </Fragment>
248
249 <!-- set to #1 if the .NET Framework 4.0 Client Danish language pack is installed (not set otherwise) -->
250 <Fragment>
251 <Property Id="NETFRAMEWORK40CLIENT_DA_DK_LANGPACK" Secure="yes">
252 <RegistrySearch Id="NETFRAMEWORK40CLIENTDaDkLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Client\1030" Name="Install" Type="raw" />
253 </Property>
254 </Fragment>
255
256 <!-- set to #1 if the .NET Framework 4.0 Client Dutch language pack is installed (not set otherwise) -->
257 <Fragment>
258 <Property Id="NETFRAMEWORK40CLIENT_NL_NL_LANGPACK" Secure="yes">
259 <RegistrySearch Id="NETFRAMEWORK40CLIENTNlNlLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Client\1043" Name="Install" Type="raw" />
260 </Property>
261 </Fragment>
262
263 <!-- set to #1 if the .NET Framework 4.0 Client Finnish language pack is installed (not set otherwise) -->
264 <Fragment>
265 <Property Id="NETFRAMEWORK40CLIENT_FI_FI_LANGPACK" Secure="yes">
266 <RegistrySearch Id="NETFRAMEWORK40CLIENTFiFiLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Client\1035" Name="Install" Type="raw" />
267 </Property>
268 </Fragment>
269
270 <!-- set to #1 if the .NET Framework 4.0 Client French language pack is installed (not set otherwise) -->
271 <Fragment>
272 <Property Id="NETFRAMEWORK40CLIENT_FR_FR_LANGPACK" Secure="yes">
273 <RegistrySearch Id="NETFRAMEWORK40CLIENTFrFrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Client\1036" Name="Install" Type="raw" />
274 </Property>
275 </Fragment>
276
277 <!-- set to #1 if the .NET Framework 4.0 Client German language pack is installed (not set otherwise) -->
278 <Fragment>
279 <Property Id="NETFRAMEWORK40CLIENT_DE_DE_LANGPACK" Secure="yes">
280 <RegistrySearch Id="NETFRAMEWORK40CLIENTDeDeLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Client\1031" Name="Install" Type="raw" />
281 </Property>
282 </Fragment>
283
284 <!-- set to #1 if the .NET Framework 4.0 Client Greek language pack is installed (not set otherwise) -->
285 <Fragment>
286 <Property Id="NETFRAMEWORK40CLIENT_EL_GR_LANGPACK" Secure="yes">
287 <RegistrySearch Id="NETFRAMEWORK40CLIENTElGrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Client\1032" Name="Install" Type="raw" />
288 </Property>
289 </Fragment>
290
291 <!-- set to #1 if the .NET Framework 4.0 Client Hebrew language pack is installed (not set otherwise) -->
292 <Fragment>
293 <Property Id="NETFRAMEWORK40CLIENT_HE_IL_LANGPACK" Secure="yes">
294 <RegistrySearch Id="NETFRAMEWORK40CLIENTHeIlLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Client\1037" Name="Install" Type="raw" />
295 </Property>
296 </Fragment>
297
298 <!-- set to #1 if the .NET Framework 4.0 Client Hungarian language pack is installed (not set otherwise) -->
299 <Fragment>
300 <Property Id="NETFRAMEWORK40CLIENT_HU_HU_LANGPACK" Secure="yes">
301 <RegistrySearch Id="NETFRAMEWORK40CLIENTHuHuLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Client\1038" Name="Install" Type="raw" />
302 </Property>
303 </Fragment>
304
305 <!-- set to #1 if the .NET Framework 4.0 Client Italian language pack is installed (not set otherwise) -->
306 <Fragment>
307 <Property Id="NETFRAMEWORK40CLIENT_IT_IT_LANGPACK" Secure="yes">
308 <RegistrySearch Id="NETFRAMEWORK40CLIENTItItLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Client\1040" Name="Install" Type="raw" />
309 </Property>
310 </Fragment>
311
312 <!-- set to #1 if the .NET Framework 4.0 Client Japanese language pack is installed (not set otherwise) -->
313 <Fragment>
314 <Property Id="NETFRAMEWORK40CLIENT_JA_JP_LANGPACK" Secure="yes">
315 <RegistrySearch Id="NETFRAMEWORK40CLIENTJaJpLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Client\1041" Name="Install" Type="raw" />
316 </Property>
317 </Fragment>
318
319 <!-- set to #1 if the .NET Framework 4.0 Client Korean language pack is installed (not set otherwise) -->
320 <Fragment>
321 <Property Id="NETFRAMEWORK40CLIENT_KO_KR_LANGPACK" Secure="yes">
322 <RegistrySearch Id="NETFRAMEWORK40CLIENTKoKrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Client\1042" Name="Install" Type="raw" />
323 </Property>
324 </Fragment>
325
326 <!-- set to #1 if the .NET Framework 4.0 Client Norwegian language pack is installed (not set otherwise) -->
327 <Fragment>
328 <Property Id="NETFRAMEWORK40CLIENT_NB_NO_LANGPACK" Secure="yes">
329 <RegistrySearch Id="NETFRAMEWORK40CLIENTNbNoLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Client\1044" Name="Install" Type="raw" />
330 </Property>
331 </Fragment>
332
333 <!-- set to #1 if the .NET Framework 4.0 Client Polish language pack is installed (not set otherwise) -->
334 <Fragment>
335 <Property Id="NETFRAMEWORK40CLIENT_PL_PL_LANGPACK" Secure="yes">
336 <RegistrySearch Id="NETFRAMEWORK40CLIENTPlPlLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Client\1045" Name="Install" Type="raw" />
337 </Property>
338 </Fragment>
339
340 <!-- set to #1 if the .NET Framework 4.0 Client Portuguese (Brazil) language pack is installed (not set otherwise) -->
341 <Fragment>
342 <Property Id="NETFRAMEWORK40CLIENT_PT_BR_LANGPACK" Secure="yes">
343 <RegistrySearch Id="NETFRAMEWORK40CLIENTPtBrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Client\1046" Name="Install" Type="raw" />
344 </Property>
345 </Fragment>
346
347 <!-- set to #1 if the .NET Framework 4.0 Client Portuguese (Portugal) language pack is installed (not set otherwise) -->
348 <Fragment>
349 <Property Id="NETFRAMEWORK40CLIENT_PT_PT_LANGPACK" Secure="yes">
350 <RegistrySearch Id="NETFRAMEWORK40CLIENTPtPtLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Client\2070" Name="Install" Type="raw" />
351 </Property>
352 </Fragment>
353
354 <!-- set to #1 if the .NET Framework 4.0 Client Russian language pack is installed (not set otherwise) -->
355 <Fragment>
356 <Property Id="NETFRAMEWORK40CLIENT_RU_RU_LANGPACK" Secure="yes">
357 <RegistrySearch Id="NETFRAMEWORK40CLIENTRuRuLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Client\1049" Name="Install" Type="raw" />
358 </Property>
359 </Fragment>
360
361 <!-- set to #1 if the .NET Framework 4.0 Client Spanish language pack is installed (not set otherwise) -->
362 <Fragment>
363 <Property Id="NETFRAMEWORK40CLIENT_ES_ES_LANGPACK" Secure="yes">
364 <RegistrySearch Id="NETFRAMEWORK40CLIENTEsEsLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Client\3082" Name="Install" Type="raw" />
365 </Property>
366 </Fragment>
367
368 <!-- set to #1 if the .NET Framework 4.0 Client Swedish language pack is installed (not set otherwise) -->
369 <Fragment>
370 <Property Id="NETFRAMEWORK40CLIENT_SV_SE_LANGPACK" Secure="yes">
371 <RegistrySearch Id="NETFRAMEWORK40CLIENTSvSeLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Client\1053" Name="Install" Type="raw" />
372 </Property>
373 </Fragment>
374
375 <!-- set to #1 if the .NET Framework 4.0 Client Turkish language pack is installed (not set otherwise) -->
376 <Fragment>
377 <Property Id="NETFRAMEWORK40CLIENT_TR_TR_LANGPACK" Secure="yes">
378 <RegistrySearch Id="NETFRAMEWORK40CLIENTTrTrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Client\1055" Name="Install" Type="raw" />
379 </Property>
380 </Fragment>
381
382 <!-- set to #1 if the .NET Framework 4.0 Full Arabic language pack is installed (not set otherwise) -->
383 <Fragment>
384 <Property Id="NETFRAMEWORK40FULL_AR_SA_LANGPACK" Secure="yes">
385 <RegistrySearch Id="NETFRAMEWORK40FULLArSaLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1025" Name="Install" Type="raw" />
386 </Property>
387 </Fragment>
388
389 <!-- set to #1 if the .NET Framework 4.0 Full Chinese (Simplified) language pack is installed (not set otherwise) -->
390 <Fragment>
391 <Property Id="NETFRAMEWORK40FULL_ZH_CN_LANGPACK" Secure="yes">
392 <RegistrySearch Id="NETFRAMEWORK40FULLZhCnLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\2052" Name="Install" Type="raw" />
393 </Property>
394 </Fragment>
395
396 <!-- set to #1 if the .NET Framework 4.0 Full Chinese (Traditional) language pack is installed (not set otherwise) -->
397 <Fragment>
398 <Property Id="NETFRAMEWORK40FULL_ZH_TW_LANGPACK" Secure="yes">
399 <RegistrySearch Id="NETFRAMEWORK40FULLZhTwLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1028" Name="Install" Type="raw" />
400 </Property>
401 </Fragment>
402
403 <!-- set to #1 if the .NET Framework 4.0 Full Czech language pack is installed (not set otherwise) -->
404 <Fragment>
405 <Property Id="NETFRAMEWORK40FULL_CS_CZ_LANGPACK" Secure="yes">
406 <RegistrySearch Id="NETFRAMEWORK40FULLCsCzLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1029" Name="Install" Type="raw" />
407 </Property>
408 </Fragment>
409
410 <!-- set to #1 if the .NET Framework 4.0 Full Danish language pack is installed (not set otherwise) -->
411 <Fragment>
412 <Property Id="NETFRAMEWORK40FULL_DA_DK_LANGPACK" Secure="yes">
413 <RegistrySearch Id="NETFRAMEWORK40FULLDaDkLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1030" Name="Install" Type="raw" />
414 </Property>
415 </Fragment>
416
417 <!-- set to #1 if the .NET Framework 4.0 Full Dutch language pack is installed (not set otherwise) -->
418 <Fragment>
419 <Property Id="NETFRAMEWORK40FULL_NL_NL_LANGPACK" Secure="yes">
420 <RegistrySearch Id="NETFRAMEWORK40FULLNlNlLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1043" Name="Install" Type="raw" />
421 </Property>
422 </Fragment>
423
424 <!-- set to #1 if the .NET Framework 4.0 Full Finnish language pack is installed (not set otherwise) -->
425 <Fragment>
426 <Property Id="NETFRAMEWORK40FULL_FI_FI_LANGPACK" Secure="yes">
427 <RegistrySearch Id="NETFRAMEWORK40FULLFiFiLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1035" Name="Install" Type="raw" />
428 </Property>
429 </Fragment>
430
431 <!-- set to #1 if the .NET Framework 4.0 Full French language pack is installed (not set otherwise) -->
432 <Fragment>
433 <Property Id="NETFRAMEWORK40FULL_FR_FR_LANGPACK" Secure="yes">
434 <RegistrySearch Id="NETFRAMEWORK40FULLFrFrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1036" Name="Install" Type="raw" />
435 </Property>
436 </Fragment>
437
438 <!-- set to #1 if the .NET Framework 4.0 Full German language pack is installed (not set otherwise) -->
439 <Fragment>
440 <Property Id="NETFRAMEWORK40FULL_DE_DE_LANGPACK" Secure="yes">
441 <RegistrySearch Id="NETFRAMEWORK40FULLDeDeLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1031" Name="Install" Type="raw" />
442 </Property>
443 </Fragment>
444
445 <!-- set to #1 if the .NET Framework 4.0 Full Greek language pack is installed (not set otherwise) -->
446 <Fragment>
447 <Property Id="NETFRAMEWORK40FULL_EL_GR_LANGPACK" Secure="yes">
448 <RegistrySearch Id="NETFRAMEWORK40FULLElGrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1032" Name="Install" Type="raw" />
449 </Property>
450 </Fragment>
451
452 <!-- set to #1 if the .NET Framework 4.0 Full Hebrew language pack is installed (not set otherwise) -->
453 <Fragment>
454 <Property Id="NETFRAMEWORK40FULL_HE_IL_LANGPACK" Secure="yes">
455 <RegistrySearch Id="NETFRAMEWORK40FULLHeIlLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1037" Name="Install" Type="raw" />
456 </Property>
457 </Fragment>
458
459 <!-- set to #1 if the .NET Framework 4.0 Full Hungarian language pack is installed (not set otherwise) -->
460 <Fragment>
461 <Property Id="NETFRAMEWORK40FULL_HU_HU_LANGPACK" Secure="yes">
462 <RegistrySearch Id="NETFRAMEWORK40FULLHuHuLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1038" Name="Install" Type="raw" />
463 </Property>
464 </Fragment>
465
466 <!-- set to #1 if the .NET Framework 4.0 Full Italian language pack is installed (not set otherwise) -->
467 <Fragment>
468 <Property Id="NETFRAMEWORK40FULL_IT_IT_LANGPACK" Secure="yes">
469 <RegistrySearch Id="NETFRAMEWORK40FULLItItLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1040" Name="Install" Type="raw" />
470 </Property>
471 </Fragment>
472
473 <!-- set to #1 if the .NET Framework 4.0 Full Japanese language pack is installed (not set otherwise) -->
474 <Fragment>
475 <Property Id="NETFRAMEWORK40FULL_JA_JP_LANGPACK" Secure="yes">
476 <RegistrySearch Id="NETFRAMEWORK40FULLJaJpLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1041" Name="Install" Type="raw" />
477 </Property>
478 </Fragment>
479
480 <!-- set to #1 if the .NET Framework 4.0 Full Korean language pack is installed (not set otherwise) -->
481 <Fragment>
482 <Property Id="NETFRAMEWORK40FULL_KO_KR_LANGPACK" Secure="yes">
483 <RegistrySearch Id="NETFRAMEWORK40FULLKoKrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1042" Name="Install" Type="raw" />
484 </Property>
485 </Fragment>
486
487 <!-- set to #1 if the .NET Framework 4.0 Full Norwegian language pack is installed (not set otherwise) -->
488 <Fragment>
489 <Property Id="NETFRAMEWORK40FULL_NB_NO_LANGPACK" Secure="yes">
490 <RegistrySearch Id="NETFRAMEWORK40FULLNbNoLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1044" Name="Install" Type="raw" />
491 </Property>
492 </Fragment>
493
494 <!-- set to #1 if the .NET Framework 4.0 Full Polish language pack is installed (not set otherwise) -->
495 <Fragment>
496 <Property Id="NETFRAMEWORK40FULL_PL_PL_LANGPACK" Secure="yes">
497 <RegistrySearch Id="NETFRAMEWORK40FULLPlPlLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1045" Name="Install" Type="raw" />
498 </Property>
499 </Fragment>
500
501 <!-- set to #1 if the .NET Framework 4.0 Full Portuguese (Brazil) language pack is installed (not set otherwise) -->
502 <Fragment>
503 <Property Id="NETFRAMEWORK40FULL_PT_BR_LANGPACK" Secure="yes">
504 <RegistrySearch Id="NETFRAMEWORK40FULLPtBrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1046" Name="Install" Type="raw" />
505 </Property>
506 </Fragment>
507
508 <!-- set to #1 if the .NET Framework 4.0 Full Portuguese (Portugal) language pack is installed (not set otherwise) -->
509 <Fragment>
510 <Property Id="NETFRAMEWORK40FULL_PT_PT_LANGPACK" Secure="yes">
511 <RegistrySearch Id="NETFRAMEWORK40FULLPtPtLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\2070" Name="Install" Type="raw" />
512 </Property>
513 </Fragment>
514
515 <!-- set to #1 if the .NET Framework 4.0 Full Russian language pack is installed (not set otherwise) -->
516 <Fragment>
517 <Property Id="NETFRAMEWORK40FULL_RU_RU_LANGPACK" Secure="yes">
518 <RegistrySearch Id="NETFRAMEWORK40FULLRuRuLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1049" Name="Install" Type="raw" />
519 </Property>
520 </Fragment>
521
522 <!-- set to #1 if the .NET Framework 4.0 Full Spanish language pack is installed (not set otherwise) -->
523 <Fragment>
524 <Property Id="NETFRAMEWORK40FULL_ES_ES_LANGPACK" Secure="yes">
525 <RegistrySearch Id="NETFRAMEWORK40FULLEsEsLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\3082" Name="Install" Type="raw" />
526 </Property>
527 </Fragment>
528
529 <!-- set to #1 if the .NET Framework 4.0 Full Swedish language pack is installed (not set otherwise) -->
530 <Fragment>
531 <Property Id="NETFRAMEWORK40FULL_SV_SE_LANGPACK" Secure="yes">
532 <RegistrySearch Id="NETFRAMEWORK40FULLSvSeLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1053" Name="Install" Type="raw" />
533 </Property>
534 </Fragment>
535
536 <!-- set to #1 if the .NET Framework 4.0 Full Turkish language pack is installed (not set otherwise) -->
537 <Fragment>
538 <Property Id="NETFRAMEWORK40FULL_TR_TR_LANGPACK" Secure="yes">
539 <RegistrySearch Id="NETFRAMEWORK40FULLTrTrLp" Root="HKLM" Key="Software\Microsoft\NET Framework Setup\NDP\v4\Full\1055" Name="Install" Type="raw" />
540 </Property>
541 </Fragment>
542
543</Wix>
diff --git a/src/wixlib/NetFx451.wxs b/src/wixlib/NetFx451.wxs
new file mode 100644
index 00000000..7feff124
--- /dev/null
+++ b/src/wixlib/NetFx451.wxs
@@ -0,0 +1,96 @@
1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. -->
3
4
5<Wix xmlns="http://wixtoolset.org/schemas/v4/wxs" xmlns:util="http://wixtoolset.org/schemas/v4/wxs/util">
6
7 <!--
8 .NET Framework installation state properties
9
10 Official documentation can be found at the following location:
11
12 .NET Framework 4.5/4.5.1 - http://msdn.microsoft.com/en-us/library/5a4x27ek.aspx, http://msdn.microsoft.com/en-us/library/ee942965(v=VS.110).aspx
13 -->
14
15 <?define NetFx451MinRelease = 378675 ?>
16 <?define NetFx451WebLink = http://go.microsoft.com/fwlink/?LinkId=322115 ?>
17 <?define NetFx451RedistLink = http://go.microsoft.com/fwlink/?LinkId=322116 ?>
18
19 <Fragment>
20 <PropertyRef Id="WIXNETFX4RELEASEINSTALLED" />
21 <Property Id="WIX_IS_NETFRAMEWORK_451_OR_LATER_INSTALLED" Secure="yes" />
22 <SetProperty Id="WIX_IS_NETFRAMEWORK_451_OR_LATER_INSTALLED" Value="1" After="AppSearch">
23 WIXNETFX4RELEASEINSTALLED >= "#$(var.NetFx451MinRelease)"
24 </SetProperty>
25 </Fragment>
26
27 <Fragment>
28 <util:RegistrySearchRef Id="NETFRAMEWORK45"/>
29
30 <WixVariable Id="NetFx451WebDetectCondition" Value="NETFRAMEWORK45 &gt;= $(var.NetFx451MinRelease)" Overridable="yes" />
31 <WixVariable Id="NetFx451WebInstallCondition" Value="" Overridable="yes" />
32 <WixVariable Id="NetFx451WebPackageDirectory" Value="redist\" Overridable="yes" />
33
34 <PackageGroup Id="NetFx451Web">
35 <ExePackage
36 InstallCommand="/q /norestart /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx451FullWebLog].html&quot;"
37 RepairCommand="/q /norestart /repair /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx451FullWebLog].html&quot;"
38 UninstallCommand="/uninstall /q /norestart /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx451FullWebLog].html&quot;"
39 PerMachine="yes"
40 DetectCondition="!(wix.NetFx451WebDetectCondition)"
41 InstallCondition="!(wix.NetFx451WebInstallCondition)"
42 Id="NetFx451Web"
43 Vital="yes"
44 Permanent="yes"
45 Protocol="netfx4"
46 DownloadUrl="$(var.NetFx451WebLink)"
47 LogPathVariable="NetFx451FullWebLog"
48 Compressed="no"
49 Name="!(wix.NetFx451WebPackageDirectory)NDP451-KB2859818-Web.exe">
50 <RemotePayload
51 Size="1021432"
52 Version="4.5.50938.18408"
53 ProductName="Microsoft .NET Framework 4.5.1"
54 Description="Microsoft .NET Framework 4.5.1 Setup"
55 CertificatePublicKey="A260A870BE1145ED71E2BB5AA19463A4FE9DCC41"
56 CertificateThumbprint="108E2BA23632620C427C570B6D9DB51AC31387FE"
57 Hash="4CBEA1E408DB5B423E130931B9478972E6798431" />
58 </ExePackage>
59 </PackageGroup>
60 </Fragment>
61
62 <Fragment>
63 <util:RegistrySearchRef Id="NETFRAMEWORK45"/>
64
65 <WixVariable Id="NetFx451RedistDetectCondition" Value="NETFRAMEWORK45 &gt;= $(var.NetFx451MinRelease)" Overridable="yes" />
66 <WixVariable Id="NetFx451RedistInstallCondition" Value="" Overridable="yes" />
67 <WixVariable Id="NetFx451RedistPackageDirectory" Value="redist\" Overridable="yes" />
68
69 <PackageGroup Id="NetFx451Redist">
70 <ExePackage
71 InstallCommand="/q /norestart /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx451FullLog].html&quot;"
72 RepairCommand="/q /norestart /repair /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx451FullLog].html&quot;"
73 UninstallCommand="/uninstall /q /norestart /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx451FullLog].html&quot;"
74 PerMachine="yes"
75 DetectCondition="!(wix.NetFx451RedistDetectCondition)"
76 InstallCondition="!(wix.NetFx451RedistInstallCondition)"
77 Id="NetFx451Redist"
78 Vital="yes"
79 Permanent="yes"
80 Protocol="netfx4"
81 DownloadUrl="$(var.NetFx451RedistLink)"
82 LogPathVariable="NetFx451FullLog"
83 Compressed="no"
84 Name="!(wix.NetFx451RedistPackageDirectory)NDP451-KB2858728-x86-x64-AllOS-ENU.exe">
85 <RemotePayload
86 Size="70087104"
87 Version="4.5.50938.18408"
88 ProductName="Microsoft .NET Framework 4.5.1"
89 Description="Microsoft .NET Framework 4.5.1 Setup"
90 CertificatePublicKey="A260A870BE1145ED71E2BB5AA19463A4FE9DCC41"
91 CertificateThumbprint="108E2BA23632620C427C570B6D9DB51AC31387FE"
92 Hash="5934DD101414BBC0B7F1EE2780D2FC8B9BEC5C4D" />
93 </ExePackage>
94 </PackageGroup>
95 </Fragment>
96</Wix>
diff --git a/src/wixlib/NetFx452.wxs b/src/wixlib/NetFx452.wxs
new file mode 100644
index 00000000..16c55aac
--- /dev/null
+++ b/src/wixlib/NetFx452.wxs
@@ -0,0 +1,95 @@
1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. -->
3
4
5<Wix xmlns="http://wixtoolset.org/schemas/v4/wxs" xmlns:util="http://wixtoolset.org/schemas/v4/wxs/util">
6
7 <!--
8 .NET Framework installation state properties
9
10 Official documentation can be found at the following location:
11
12 .NET Framework 4.5/4.5.1/4.5.2 - http://msdn.microsoft.com/en-us/library/w0x726c2(v=vs.110).aspx
13 -->
14
15 <?define NetFx452MinRelease = 379893 ?>
16 <?define NetFx452WebLink = http://go.microsoft.com/fwlink/?LinkId=397707 ?>
17 <?define NetFx452RedistLink = http://go.microsoft.com/fwlink/?LinkId=397708 ?>
18
19 <Fragment>
20 <PropertyRef Id="WIXNETFX4RELEASEINSTALLED" />
21 <Property Id="WIX_IS_NETFRAMEWORK_452_OR_LATER_INSTALLED" Secure="yes" />
22 <SetProperty Id="WIX_IS_NETFRAMEWORK_452_OR_LATER_INSTALLED" Value="1" After="AppSearch">
23 WIXNETFX4RELEASEINSTALLED >= "#$(var.NetFx452MinRelease)"
24 </SetProperty>
25 </Fragment>
26
27 <Fragment>
28 <util:RegistrySearchRef Id="NETFRAMEWORK45"/>
29
30 <WixVariable Id="NetFx452WebDetectCondition" Value="NETFRAMEWORK45 &gt;= $(var.NetFx452MinRelease)" Overridable="yes" />
31 <WixVariable Id="NetFx452WebInstallCondition" Value="" Overridable="yes" />
32 <WixVariable Id="NetFx452WebPackageDirectory" Value="redist\" Overridable="yes" />
33
34 <PackageGroup Id="NetFx452Web">
35 <ExePackage
36 InstallCommand="/q /norestart /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx452FullWebLog].html&quot;"
37 RepairCommand="/q /norestart /repair /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx452FullWebLog].html&quot;"
38 UninstallCommand="/uninstall /q /norestart /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx452FullWebLog].html&quot;"
39 PerMachine="yes"
40 DetectCondition="!(wix.NetFx452WebDetectCondition)"
41 InstallCondition="!(wix.NetFx452WebInstallCondition)"
42 Id="NetFx452Web"
43 Vital="yes"
44 Permanent="yes"
45 Protocol="netfx4"
46 DownloadUrl="$(var.NetFx452WebLink)"
47 LogPathVariable="NetFx452FullWebLog"
48 Compressed="no"
49 Name="!(wix.NetFx452WebPackageDirectory)NDP452-KB2901954-Web.exe">
50 <RemotePayload CertificatePublicKey="B78FE7F6917E1BC5F4A9C77BA3D555A0E807B9E0"
51 CertificateThumbprint="67B1757863E3EFF760EA9EBB02849AF07D3A8080"
52 Description="Microsoft .NET Framework 4.5.2 Setup"
53 Hash="5B71B20A455F6EEAB79DD1EDCAB0BA66AD0D2208"
54 ProductName="Microsoft .NET Framework 4.5.2"
55 Size="1118920"
56 Version="4.5.51209.34209" />
57 </ExePackage>
58 </PackageGroup>
59 </Fragment>
60
61 <Fragment>
62 <util:RegistrySearchRef Id="NETFRAMEWORK45"/>
63
64 <WixVariable Id="NetFx452RedistDetectCondition" Value="NETFRAMEWORK45 &gt;= $(var.NetFx452MinRelease)" Overridable="yes" />
65 <WixVariable Id="NetFx452RedistInstallCondition" Value="" Overridable="yes" />
66 <WixVariable Id="NetFx452RedistPackageDirectory" Value="redist\" Overridable="yes" />
67
68 <PackageGroup Id="NetFx452Redist">
69 <ExePackage
70 InstallCommand="/q /norestart /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx452FullLog].html&quot;"
71 RepairCommand="/q /norestart /repair /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx452FullLog].html&quot;"
72 UninstallCommand="/uninstall /q /norestart /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx452FullLog].html&quot;"
73 PerMachine="yes"
74 DetectCondition="!(wix.NetFx452RedistDetectCondition)"
75 InstallCondition="!(wix.NetFx452RedistInstallCondition)"
76 Id="NetFx452Redist"
77 Vital="yes"
78 Permanent="yes"
79 Protocol="netfx4"
80 DownloadUrl="$(var.NetFx452RedistLink)"
81 LogPathVariable="NetFx452FullLog"
82 Compressed="no"
83 Name="!(wix.NetFx452RedistPackageDirectory)NDP452-KB2901907-x86-x64-AllOS-ENU.exe">
84 <RemotePayload
85 CertificatePublicKey="B78FE7F6917E1BC5F4A9C77BA3D555A0E807B9E0"
86 CertificateThumbprint="67B1757863E3EFF760EA9EBB02849AF07D3A8080"
87 Description="Microsoft .NET Framework 4.5.2 Setup"
88 Hash="89F86F9522DC7A8A965FACCE839ABB790A285A63"
89 ProductName="Microsoft .NET Framework 4.5.2"
90 Size="69999448"
91 Version="4.5.51209.34209" />
92 </ExePackage>
93 </PackageGroup>
94 </Fragment>
95</Wix>
diff --git a/src/wixlib/NetFx46.wxs b/src/wixlib/NetFx46.wxs
new file mode 100644
index 00000000..c4120e90
--- /dev/null
+++ b/src/wixlib/NetFx46.wxs
@@ -0,0 +1,96 @@
1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. -->
3
4
5<Wix xmlns="http://wixtoolset.org/schemas/v4/wxs" xmlns:util="http://wixtoolset.org/schemas/v4/wxs/util">
6
7 <!--
8 .NET Framework installation state properties
9
10 Official documentation can be found at the following location:
11
12 .NET Framework 4.5/4.5.1/4.5.2/4.6 - http://msdn.microsoft.com/en-us/library/w0x726c2(v=vs.110).aspx
13 -->
14
15 <?define NetFx46MinRelease = 393295 ?>
16 <?define NetFx46WebLink = http://go.microsoft.com/fwlink/?LinkId=560371 ?>
17 <?define NetFx46RedistLink = http://go.microsoft.com/fwlink/?LinkId=560369 ?>
18
19 <Fragment>
20 <PropertyRef Id="WIXNETFX4RELEASEINSTALLED" />
21 <Property Id="WIX_IS_NETFRAMEWORK_46_OR_LATER_INSTALLED" Secure="yes" />
22 <SetProperty Id="WIX_IS_NETFRAMEWORK_46_OR_LATER_INSTALLED" Value="1" After="AppSearch">
23 WIXNETFX4RELEASEINSTALLED >= "#$(var.NetFx46MinRelease)"
24 </SetProperty>
25 </Fragment>
26
27 <Fragment>
28 <util:RegistrySearchRef Id="NETFRAMEWORK45"/>
29
30 <WixVariable Id="NetFx46WebDetectCondition" Value="NETFRAMEWORK45 &gt;= $(var.NetFx46MinRelease)" Overridable="yes" />
31 <WixVariable Id="NetFx46WebInstallCondition" Value="" Overridable="yes" />
32 <WixVariable Id="NetFx46WebPackageDirectory" Value="redist\" Overridable="yes" />
33
34 <PackageGroup Id="NetFx46Web">
35 <ExePackage
36 InstallCommand="/q /norestart /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx46FullLog].html&quot;"
37 RepairCommand="/q /norestart /repair /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx46FullLog].html&quot;"
38 UninstallCommand="/uninstall /q /norestart /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx46FullLog].html&quot;"
39 PerMachine="yes"
40 DetectCondition="!(wix.NetFx46WebDetectCondition)"
41 InstallCondition="!(wix.NetFx46WebInstallCondition)"
42 Id="NetFx46Web"
43 Vital="yes"
44 Permanent="yes"
45 Protocol="netfx4"
46 DownloadUrl="$(var.NetFx46WebLink)"
47 LogPathVariable="NetFx46FullLog"
48 Compressed="no"
49 Name="!(wix.NetFx46WebPackageDirectory)NDP46-KB3045560-Web.exe">
50 <RemotePayload
51 CertificatePublicKey="52868DFCA6E3AF2632389E6C1EE7D0468D3797D0"
52 CertificateThumbprint="3BDA323E552DB1FDE5F4FBEE75D6D5B2B187EEDC"
53 Description="Microsoft .NET Framework 4.6 Setup"
54 Hash="480CA134B9E3F2437DF10719D5A8C77DDEC0A4F1"
55 ProductName="Microsoft .NET Framework 4.6"
56 Size="1497400"
57 Version="4.6.81.0" />
58 </ExePackage>
59 </PackageGroup>
60 </Fragment>
61
62 <Fragment>
63 <util:RegistrySearchRef Id="NETFRAMEWORK45"/>
64
65 <WixVariable Id="NetFx46RedistDetectCondition" Value="NETFRAMEWORK45 &gt;= $(var.NetFx46MinRelease)" Overridable="yes" />
66 <WixVariable Id="NetFx46RedistInstallCondition" Value="" Overridable="yes" />
67 <WixVariable Id="NetFx46RedistPackageDirectory" Value="redist\" Overridable="yes" />
68
69 <PackageGroup Id="NetFx46Redist">
70 <ExePackage
71 InstallCommand="/q /norestart /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx46FullLog].html&quot;"
72 RepairCommand="/q /norestart /repair /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx46FullLog].html&quot;"
73 UninstallCommand="/uninstall /q /norestart /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx46FullLog].html&quot;"
74 PerMachine="yes"
75 DetectCondition="!(wix.NetFx46RedistDetectCondition)"
76 InstallCondition="!(wix.NetFx46RedistInstallCondition)"
77 Id="NetFx46Redist"
78 Vital="yes"
79 Permanent="yes"
80 Protocol="netfx4"
81 DownloadUrl="$(var.NetFx46RedistLink)"
82 LogPathVariable="NetFx46FullLog"
83 Compressed="no"
84 Name="!(wix.NetFx46RedistPackageDirectory)NDP46-KB3045557-x86-x64-AllOS-ENU.exe">
85 <RemotePayload
86 CertificatePublicKey="52868DFCA6E3AF2632389E6C1EE7D0468D3797D0"
87 CertificateThumbprint="3BDA323E552DB1FDE5F4FBEE75D6D5B2B187EEDC"
88 Description="Microsoft .NET Framework 4.6 Setup"
89 Hash="3049A85843EAF65E89E2336D5FE6E85E416797BE"
90 ProductName="Microsoft .NET Framework 4.6"
91 Size="65444688"
92 Version="4.6.81.0" />
93 </ExePackage>
94 </PackageGroup>
95 </Fragment>
96</Wix>
diff --git a/src/wixlib/NetFx461.wxs b/src/wixlib/NetFx461.wxs
new file mode 100644
index 00000000..907c2a35
--- /dev/null
+++ b/src/wixlib/NetFx461.wxs
@@ -0,0 +1,95 @@
1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. -->
3
4<Wix xmlns="http://wixtoolset.org/schemas/v4/wxs" xmlns:util="http://wixtoolset.org/schemas/v4/wxs/util">
5
6 <!--
7 .NET Framework installation state properties
8
9 Official documentation can be found at the following location:
10
11 .NET Framework 4.5/4.5.1/4.5.2/4.6/4.6.1 - http://msdn.microsoft.com/en-us/library/w0x726c2(v=vs.110).aspx
12 -->
13
14 <?define NetFx461MinRelease = 394254 ?>
15 <?define NetFx461WebLink = http://go.microsoft.com/fwlink/?LinkId=671728 ?>
16 <?define NetFx461RedistLink = http://go.microsoft.com/fwlink/?LinkId=671743 ?>
17
18 <Fragment>
19 <PropertyRef Id="WIXNETFX4RELEASEINSTALLED" />
20 <Property Id="WIX_IS_NETFRAMEWORK_461_OR_LATER_INSTALLED" Secure="yes" />
21 <SetProperty Id="WIX_IS_NETFRAMEWORK_461_OR_LATER_INSTALLED" Value="1" After="AppSearch">
22 WIXNETFX4RELEASEINSTALLED >= "#$(var.NetFx461MinRelease)"
23 </SetProperty>
24 </Fragment>
25
26 <Fragment>
27 <util:RegistrySearchRef Id="NETFRAMEWORK45"/>
28
29 <WixVariable Id="NetFx461WebDetectCondition" Value="NETFRAMEWORK45 &gt;= $(var.NetFx461MinRelease)" Overridable="yes" />
30 <WixVariable Id="NetFx461WebInstallCondition" Value="" Overridable="yes" />
31 <WixVariable Id="NetFx461WebPackageDirectory" Value="redist\" Overridable="yes" />
32
33 <PackageGroup Id="NetFx461Web">
34 <ExePackage
35 InstallCommand="/q /norestart /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx461FullLog].html&quot;"
36 RepairCommand="/q /norestart /repair /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx461FullLog].html&quot;"
37 UninstallCommand="/uninstall /q /norestart /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx461FullLog].html&quot;"
38 PerMachine="yes"
39 DetectCondition="!(wix.NetFx461WebDetectCondition)"
40 InstallCondition="!(wix.NetFx461WebInstallCondition)"
41 Id="NetFx461Web"
42 Vital="yes"
43 Permanent="yes"
44 Protocol="netfx4"
45 DownloadUrl="$(var.NetFx461WebLink)"
46 LogPathVariable="NetFx461FullLog"
47 Compressed="no"
48 Name="!(wix.NetFx461WebPackageDirectory)NDP461-KB3102438-Web.exe">
49 <RemotePayload
50 CertificatePublicKey="52868DFCA6E3AF2632389E6C1EE7D0468D3797D0"
51 CertificateThumbprint="3BDA323E552DB1FDE5F4FBEE75D6D5B2B187EEDC"
52 Description="Microsoft .NET Framework 4.6.1 Setup"
53 Hash="EE88B05232F43B517D4A368F7EE5065CDE7F67FA"
54 ProductName="Microsoft .NET Framework 4.6.1"
55 Size="1424328"
56 Version="4.6.1055.0" />
57 </ExePackage>
58 </PackageGroup>
59 </Fragment>
60
61 <Fragment>
62 <util:RegistrySearchRef Id="NETFRAMEWORK45"/>
63
64 <WixVariable Id="NetFx461RedistDetectCondition" Value="NETFRAMEWORK45 &gt;= $(var.NetFx461MinRelease)" Overridable="yes" />
65 <WixVariable Id="NetFx461RedistInstallCondition" Value="" Overridable="yes" />
66 <WixVariable Id="NetFx461RedistPackageDirectory" Value="redist\" Overridable="yes" />
67
68 <PackageGroup Id="NetFx461Redist">
69 <ExePackage
70 InstallCommand="/q /norestart /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx461FullLog].html&quot;"
71 RepairCommand="/q /norestart /repair /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx461FullLog].html&quot;"
72 UninstallCommand="/uninstall /q /norestart /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx461FullLog].html&quot;"
73 PerMachine="yes"
74 DetectCondition="!(wix.NetFx461RedistDetectCondition)"
75 InstallCondition="!(wix.NetFx461RedistInstallCondition)"
76 Id="NetFx461Redist"
77 Vital="yes"
78 Permanent="yes"
79 Protocol="netfx4"
80 DownloadUrl="$(var.NetFx461RedistLink)"
81 LogPathVariable="NetFx461FullLog"
82 Compressed="no"
83 Name="!(wix.NetFx461RedistPackageDirectory)NDP461-KB3102436-x86-x64-AllOS-ENU.exe">
84 <RemotePayload
85 CertificatePublicKey="52868DFCA6E3AF2632389E6C1EE7D0468D3797D0"
86 CertificateThumbprint="3BDA323E552DB1FDE5F4FBEE75D6D5B2B187EEDC"
87 Description="Microsoft .NET Framework 4.6.1 Setup"
88 Hash="83D048D171FF44A3CAD9B422137656F585295866"
89 ProductName="Microsoft .NET Framework 4.6.1"
90 Size="67681000"
91 Version="4.6.1055.0" />
92 </ExePackage>
93 </PackageGroup>
94 </Fragment>
95</Wix>
diff --git a/src/wixlib/NetFx462.wxs b/src/wixlib/NetFx462.wxs
new file mode 100644
index 00000000..08f5bd53
--- /dev/null
+++ b/src/wixlib/NetFx462.wxs
@@ -0,0 +1,95 @@
1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. -->
3
4<Wix xmlns="http://wixtoolset.org/schemas/v4/wxs" xmlns:util="http://wixtoolset.org/schemas/v4/wxs/util">
5
6 <!--
7 .NET Framework installation state properties
8
9 Official documentation can be found at the following location:
10
11 .NET Framework 4.5/4.5.1/4.5.2/4.6/4.6.1/4.6.2 - http://msdn.microsoft.com/en-us/library/w0x726c2(v=vs.110).aspx
12 -->
13
14 <?define NetFx462MinRelease = 394802 ?>
15 <?define NetFx462WebLink = http://go.microsoft.com/fwlink/?LinkId=780596 ?>
16 <?define NetFx462RedistLink = http://go.microsoft.com/fwlink/?LinkId=780600 ?>
17
18 <Fragment>
19 <PropertyRef Id="WIXNETFX4RELEASEINSTALLED" />
20 <Property Id="WIX_IS_NETFRAMEWORK_462_OR_LATER_INSTALLED" Secure="yes" />
21 <SetProperty Id="WIX_IS_NETFRAMEWORK_462_OR_LATER_INSTALLED" Value="1" After="AppSearch">
22 WIXNETFX4RELEASEINSTALLED >= "#$(var.NetFx462MinRelease)"
23 </SetProperty>
24 </Fragment>
25
26 <Fragment>
27 <util:RegistrySearchRef Id="NETFRAMEWORK45"/>
28
29 <WixVariable Id="NetFx462WebDetectCondition" Value="NETFRAMEWORK45 &gt;= $(var.NetFx462MinRelease)" Overridable="yes" />
30 <WixVariable Id="NetFx462WebInstallCondition" Value="" Overridable="yes" />
31 <WixVariable Id="NetFx462WebPackageDirectory" Value="redist\" Overridable="yes" />
32
33 <PackageGroup Id="NetFx462Web">
34 <ExePackage
35 InstallCommand="/q /norestart /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx462FullLog].html&quot;"
36 RepairCommand="/q /norestart /repair /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx462FullLog].html&quot;"
37 UninstallCommand="/uninstall /q /norestart /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx462FullLog].html&quot;"
38 PerMachine="yes"
39 DetectCondition="!(wix.NetFx462WebDetectCondition)"
40 InstallCondition="!(wix.NetFx462WebInstallCondition)"
41 Id="NetFx462Web"
42 Vital="yes"
43 Permanent="yes"
44 Protocol="netfx4"
45 DownloadUrl="$(var.NetFx462WebLink)"
46 LogPathVariable="NetFx462FullLog"
47 Compressed="no"
48 Name="!(wix.NetFx462WebPackageDirectory)NDP462-KB3151802-Web.exe">
49 <RemotePayload
50 CertificatePublicKey="52868DFCA6E3AF2632389E6C1EE7D0468D3797D0"
51 CertificateThumbprint="3BDA323E552DB1FDE5F4FBEE75D6D5B2B187EEDC"
52 Description="Microsoft .NET Framework 4.6.2 Setup"
53 Hash="C42E6ED280290648BBD59F664008852F4CFE4548"
54 ProductName="Microsoft .NET Framework 4.6.2"
55 Size="1429344"
56 Version="4.6.1590.0" />
57 </ExePackage>
58 </PackageGroup>
59 </Fragment>
60
61 <Fragment>
62 <util:RegistrySearchRef Id="NETFRAMEWORK45"/>
63
64 <WixVariable Id="NetFx462RedistDetectCondition" Value="NETFRAMEWORK45 &gt;= $(var.NetFx462MinRelease)" Overridable="yes" />
65 <WixVariable Id="NetFx462RedistInstallCondition" Value="" Overridable="yes" />
66 <WixVariable Id="NetFx462RedistPackageDirectory" Value="redist\" Overridable="yes" />
67
68 <PackageGroup Id="NetFx462Redist">
69 <ExePackage
70 InstallCommand="/q /norestart /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx462FullLog].html&quot;"
71 RepairCommand="/q /norestart /repair /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx462FullLog].html&quot;"
72 UninstallCommand="/uninstall /q /norestart /ChainingPackage &quot;[WixBundleName]&quot; /log &quot;[NetFx462FullLog].html&quot;"
73 PerMachine="yes"
74 DetectCondition="!(wix.NetFx462RedistDetectCondition)"
75 InstallCondition="!(wix.NetFx462RedistInstallCondition)"
76 Id="NetFx462Redist"
77 Vital="yes"
78 Permanent="yes"
79 Protocol="netfx4"
80 DownloadUrl="$(var.NetFx462RedistLink)"
81 LogPathVariable="NetFx462FullLog"
82 Compressed="no"
83 Name="!(wix.NetFx462RedistPackageDirectory)NDP462-KB3151800-x86-x64-AllOS-ENU.exe">
84 <RemotePayload
85 CertificatePublicKey="52868DFCA6E3AF2632389E6C1EE7D0468D3797D0"
86 CertificateThumbprint="3BDA323E552DB1FDE5F4FBEE75D6D5B2B187EEDC"
87 Description="Microsoft .NET Framework 4.6.2 Setup"
88 Hash="A70F856BDA33D45AD0A8AD035F73092441715431"
89 ProductName="Microsoft .NET Framework 4.6.2"
90 Size="62008080"
91 Version="4.6.1590.0" />
92 </ExePackage>
93 </PackageGroup>
94 </Fragment>
95</Wix>
diff --git a/src/wixlib/NetFxExtension.wxs b/src/wixlib/NetFxExtension.wxs
new file mode 100644
index 00000000..b64dc004
--- /dev/null
+++ b/src/wixlib/NetFxExtension.wxs
@@ -0,0 +1,39 @@
1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. -->
3
4
5<Wix xmlns="http://wixtoolset.org/schemas/v4/wxs">
6
7 <!--
8 .NET Framework installation state properties
9 -->
10
11 <!-- Location of .NET Framework redistributable install root directory -->
12 <Fragment>
13 <Property Id="NETFRAMEWORKINSTALLROOTDIR" Secure="yes">
14 <RegistrySearch Id="NetFxInstallRootSearch" Type="raw" Root="HKLM" Key="Software\Microsoft\.NETFramework" Name="InstallRoot" />
15 </Property>
16 </Fragment>
17
18 <!-- location of the Windows SDK current active version installation root -->
19 <Fragment>
20 <Property Id="WINDOWSSDKCURRENTVERSIONDIR" Secure="yes">
21 <RegistrySearch Id="WindowsSdkCurrentVersionDir" Root="HKLM" Key="Software\Microsoft\Microsoft SDKs\Windows" Name="CurrentInstallFolder" Type="raw" />
22 </Property>
23 </Fragment>
24
25 <!-- The Windows SDK current active version -->
26 <Fragment>
27 <Property Id="WINDOWSSDKCURRENTVERSION" Secure="yes">
28 <RegistrySearch Id="WindowsSdkCurrentVersion" Root="HKLM" Key="Software\Microsoft\Microsoft SDKs\Windows" Name="CurrentVersion" Type="raw" />
29 </Property>
30 </Fragment>
31
32 <!-- Release value of .NET 4.5 and later -->
33 <Fragment>
34 <Property Id="WIXNETFX4RELEASEINSTALLED" Secure="yes">
35 <RegistrySearch Id="NetFx4ReleaseInstalled" Root="HKLM" Key="SOFTWARE\Microsoft\NET Framework Setup\NDP\v4\Full" Name="Release" Type="raw" />
36 </Property>
37 </Fragment>
38
39</Wix>
diff --git a/src/wixlib/NetFxExtension_Platform.wxi b/src/wixlib/NetFxExtension_Platform.wxi
new file mode 100644
index 00000000..9236f316
--- /dev/null
+++ b/src/wixlib/NetFxExtension_Platform.wxi
@@ -0,0 +1,28 @@
1<?xml version="1.0"?>
2<!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. -->
3
4
5<Include xmlns="http://wixtoolset.org/schemas/v4/wxs">
6
7 <?include caSuffix.wxi ?>
8 <Fragment>
9 <CustomAction Id="NetFxScheduleNativeImage$(var.Suffix)" BinaryKey="NetFxCA$(var.Suffix)" DllEntry="SchedNetFx" Execute="immediate" Return="check" SuppressModularization="yes" />
10 <CustomAction Id="NetFxExecuteNativeImageInstall$(var.DeferredSuffix)" BinaryKey="NetFxCA$(var.Suffix)" DllEntry="ExecNetFx" Execute="deferred" Impersonate="no" Return="ignore" SuppressModularization="yes" />
11 <CustomAction Id="NetFxExecuteNativeImageCommitInstall$(var.DeferredSuffix)" BinaryKey="NetFxCA$(var.Suffix)" DllEntry="ExecNetFx" Execute="commit" Impersonate="no" Return="ignore" SuppressModularization="yes" />
12 <CustomAction Id="NetFxExecuteNativeImageUninstall$(var.DeferredSuffix)" BinaryKey="NetFxCA$(var.Suffix)" DllEntry="ExecNetFx" Execute="deferred" Impersonate="no" Return="ignore" SuppressModularization="yes" />
13 <CustomAction Id="NetFxExecuteNativeImageCommitUninstall$(var.DeferredSuffix)" BinaryKey="NetFxCA$(var.Suffix)" DllEntry="ExecNetFx" Execute="commit" Impersonate="no" Return="ignore" SuppressModularization="yes" />
14
15 <InstallExecuteSequence>
16 <Custom Action="NetFxScheduleNativeImage$(var.Suffix)" Before="InstallFiles" Overridable="yes" />
17 <Custom Action="NetFxExecuteNativeImageCommitUninstall$(var.DeferredSuffix)" After="MsiPublishAssemblies" Overridable="yes">RollbackDisabled &lt;&gt; 1</Custom>
18 <Custom Action="NetFxExecuteNativeImageUninstall$(var.DeferredSuffix)" After="NetFxExecuteNativeImageCommitUninstall$(var.DeferredSuffix)" Overridable="yes">RollbackDisabled = 1</Custom>
19 <Custom Action="NetFxExecuteNativeImageCommitInstall$(var.DeferredSuffix)" After="NetFxExecuteNativeImageUninstall$(var.DeferredSuffix)" Overridable="yes">RollbackDisabled &lt;&gt; 1</Custom>
20 <Custom Action="NetFxExecuteNativeImageInstall$(var.DeferredSuffix)" After="NetFxExecuteNativeImageCommitInstall$(var.DeferredSuffix)" Overridable="yes">RollbackDisabled = 1</Custom>
21 </InstallExecuteSequence>
22 </Fragment>
23
24 <!-- NetFx Custom Action DLL Definitions -->
25 <Fragment>
26 <Binary Id="NetFxCA$(var.Suffix)" SourceFile="!(bindpath.$(var.platform))netfxca.dll" />
27 </Fragment>
28</Include>
diff --git a/src/wixlib/NetFxExtension_x86.wxs b/src/wixlib/NetFxExtension_x86.wxs
new file mode 100644
index 00000000..7245a4dd
--- /dev/null
+++ b/src/wixlib/NetFxExtension_x86.wxs
@@ -0,0 +1,8 @@
1<?xml version="1.0"?>
2<!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. -->
3
4
5<Wix xmlns="http://wixtoolset.org/schemas/v4/wxs">
6 <?define platform=x86 ?>
7 <?include NetfxExtension_Platform.wxi ?>
8</Wix>
diff --git a/src/wixlib/caSuffix.wxi b/src/wixlib/caSuffix.wxi
new file mode 100644
index 00000000..a56a2393
--- /dev/null
+++ b/src/wixlib/caSuffix.wxi
@@ -0,0 +1,28 @@
1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. -->
3
4<Include xmlns="http://wixtoolset.org/schemas/v4/wxs">
5 <?ifndef platform ?>
6 <?error Required value "platform" not defined in include caSuffix.wxi ?>
7 <?endif ?>
8
9 <?ifdef Suffix ?>
10 <?undef Suffix ?>
11 <?undef DeferredSuffix ?>
12 <?endif ?>
13
14 <?if $(var.platform)="x86" ?>
15 <?define Suffix="" ?>
16 <?define DeferredSuffix="" ?>
17 <?endif ?>
18
19 <?if $(var.platform)="x64" ?>
20 <?define Suffix="_x64" ?>
21 <?define DeferredSuffix="_64" ?>
22 <?endif ?>
23
24 <?if $(var.platform)="arm" ?>
25 <?define Suffix="_ARM" ?>
26 <?define DeferredSuffix="_ARM" ?>
27 <?endif ?>
28</Include>
diff --git a/src/wixlib/netfx.wixproj b/src/wixlib/netfx.wixproj
new file mode 100644
index 00000000..8a734c84
--- /dev/null
+++ b/src/wixlib/netfx.wixproj
@@ -0,0 +1,53 @@
1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. -->
3<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="15.0">
4 <Import Project="..\..\packages\WixToolset.Core.InternalPackage.4.0.64\build\WixToolset.Core.InternalPackage.props" Condition="Exists('..\..\packages\WixToolset.Core.InternalPackage.4.0.64\build\WixToolset.Core.InternalPackage.props')" />
5 <Import Project="..\FindLocalWix.props" />
6 <PropertyGroup>
7 <ProjectGuid>{45e4a6ac-3190-4e17-83f0-9935ffa5dc2b}</ProjectGuid>
8 <OutputName>netfx</OutputName>
9 <OutputType>Library</OutputType>
10 <BindFiles>true</BindFiles>
11 <Pedantic>true</Pedantic>
12 </PropertyGroup>
13 <ItemGroup>
14 <Compile Include="NetFxExtension.wxs" />
15 <Compile Include="NetFx1.wxs" />
16 <Compile Include="NetFx1.1.wxs" />
17 <Compile Include="NetFx2.wxs" />
18 <Compile Include="NetFx3.wxs" />
19 <Compile Include="NetFx3.5.wxs" />
20 <Compile Include="NetFx4.wxs" />
21 <Compile Include="NetFx4.5.wxs" />
22 <Compile Include="NetFx451.wxs" />
23 <Compile Include="NetFx452.wxs" />
24 <Compile Include="NetFx46.wxs" />
25 <Compile Include="NetFx461.wxs" />
26 <Compile Include="NetFx462.wxs" />
27 <Compile Include="NetFxExtension_x86.wxs" />
28 </ItemGroup>
29 <ItemGroup>
30 <None Include="packages.config" />
31 </ItemGroup>
32 <ItemGroup>
33 <ProjectReference Include="..\ca\netfxca.vcxproj">
34 <Name>netfxca</Name>
35 <Project>{F72D34CA-48DA-4DFD-91A9-A0C78BEF6981}</Project>
36 </ProjectReference>
37 </ItemGroup>
38 <Import Project="$(WixTargetsPath)" Condition=" '$(WixTargetsPath)' != '' AND Exists('$(WixTargetsPath)') " />
39 <Import Project="$(MSBuildExtensionsPath32)\Microsoft\WiX\v3.x\wix.targets" Condition=" '$(WixTargetsPath)' == '' AND Exists('$(MSBuildExtensionsPath32)\Microsoft\WiX\v3.x\wix.targets') " />
40 <Target Name="EnsureWixToolsetInstalled" Condition=" '$(WixTargetsImported)' != 'true' ">
41 <Error Text="FG-WiX or WiX Toolset build tools (v3.11 or later) must be installed to build this project. To download FG-WiX, go to https://www.firegiant.com/downloads/. To download the WiX Toolset, go to http://wixtoolset.org/releases/." />
42 </Target>
43 <Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
44 <PropertyGroup>
45 <ErrorText>This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
46 </PropertyGroup>
47 <Error Condition="!Exists('..\..\packages\Nerdbank.GitVersioning.2.1.7\build\Nerdbank.GitVersioning.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\..\packages\Nerdbank.GitVersioning.2.1.7\build\Nerdbank.GitVersioning.targets'))" />
48 <Error Condition="!Exists('..\..\packages\WixToolset.Util.wixext.4.0.1\build\WixToolset.Util.wixext.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\..\packages\WixToolset.Util.wixext.4.0.1\build\WixToolset.Util.wixext.targets'))" />
49 <Error Condition="!Exists('..\..\packages\WixToolset.Core.InternalPackage.4.0.64\build\WixToolset.Core.InternalPackage.props')" Text="$([System.String]::Format('$(ErrorText)', '..\..\packages\WixToolset.Core.InternalPackage.4.0.64\build\WixToolset.Core.InternalPackage.props'))" />
50 </Target>
51 <Import Project="..\..\packages\Nerdbank.GitVersioning.2.1.7\build\Nerdbank.GitVersioning.targets" Condition="Exists('..\..\packages\Nerdbank.GitVersioning.2.1.7\build\Nerdbank.GitVersioning.targets')" />
52 <Import Project="..\..\packages\WixToolset.Util.wixext.4.0.1\build\WixToolset.Util.wixext.targets" Condition="Exists('..\..\packages\WixToolset.Util.wixext.4.0.1\build\WixToolset.Util.wixext.targets')" />
53</Project> \ No newline at end of file
diff --git a/src/wixlib/packages.config b/src/wixlib/packages.config
new file mode 100644
index 00000000..ba130574
--- /dev/null
+++ b/src/wixlib/packages.config
@@ -0,0 +1,6 @@
1<?xml version="1.0" encoding="utf-8"?>
2<packages>
3 <package id="Nerdbank.GitVersioning" version="2.1.7" developmentDependency="true" targetFramework="net40" />
4 <package id="WixToolset.Core.InternalPackage" version="4.0.64" targetFramework="net40" developmentDependency="true" />
5 <package id="WixToolset.Util.wixext" version="4.0.1" targetFramework="net40" />
6</packages> \ No newline at end of file
diff --git a/version.json b/version.json
new file mode 100644
index 00000000..5f857771
--- /dev/null
+++ b/version.json
@@ -0,0 +1,11 @@
1{
2 "version": "4.0",
3 "publicReleaseRefSpec": [
4 "^refs/heads/master$"
5 ],
6 "cloudBuild": {
7 "buildNumber": {
8 "enabled": true
9 }
10 }
11}