aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSean Hall <r.sean.hall@gmail.com>2022-02-18 17:22:11 -0600
committerSean Hall <r.sean.hall@gmail.com>2022-02-18 17:05:47 -0700
commit62224cf5c909c6b9ea09eeb0bcf29021091e7665 (patch)
treef2866cf00ec727e9b483cf86a16449f245d07d2d
parenta16cd379b5de4563f263fa45922e59c698eb17fb (diff)
downloadwix-62224cf5c909c6b9ea09eeb0bcf29021091e7665.tar.gz
wix-62224cf5c909c6b9ea09eeb0bcf29021091e7665.tar.bz2
wix-62224cf5c909c6b9ea09eeb0bcf29021091e7665.zip
Create RequiresNativeWixAssets property.
-rw-r--r--src/wix/Directory.Build.targets39
-rw-r--r--src/wix/test/WixToolsetTest.BuildTasks/WixToolsetTest.BuildTasks.csproj7
-rw-r--r--src/wix/test/WixToolsetTest.Core.Native/WixToolsetTest.Core.Native.csproj7
-rw-r--r--src/wix/test/WixToolsetTest.CoreIntegration/WixToolsetTest.CoreIntegration.csproj7
-rw-r--r--src/wix/test/WixToolsetTest.Sdk/WixToolsetTest.Sdk.csproj7
-rw-r--r--src/wix/wix/wix.csproj35
6 files changed, 44 insertions, 58 deletions
diff --git a/src/wix/Directory.Build.targets b/src/wix/Directory.Build.targets
new file mode 100644
index 00000000..d3c60a1e
--- /dev/null
+++ b/src/wix/Directory.Build.targets
@@ -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<Project>
4 <Import Project="..\Directory.Build.targets" />
5
6 <ItemGroup Condition=" '$(RequiresNativeWixAssets)'=='true' and ('$(TargetFrameworkIdentifier)'=='.NETFramework' or '$(RuntimeIdentifier)'!='' ) ">
7 <!-- Copy the x64 binaries when there is no RuntimeIdentifier since we've standardized on VS2022 (which is 64-bit) -->
8 <None Include="$(MSBuildThisFileDirectory)wixnative\x64\mergemod.dll" CopyToOutputDirectory="PreserveNewest" Condition=" '$(RuntimeIdentifier)'=='win-x64' or '$(RuntimeIdentifier)'=='' " />
9 <None Include="$(BaseOutputPath)$(Configuration)\x64\wixnative.exe" CopyToOutputDirectory="PreserveNewest" Condition=" '$(RuntimeIdentifier)'=='win-x64' or '$(RuntimeIdentifier)'=='' " />
10
11 <None Include="$(MSBuildThisFileDirectory)wixnative\Win32\mergemod.dll" CopyToOutputDirectory="PreserveNewest" Condition=" '$(RuntimeIdentifier)'=='win-x86' " />
12 <None Include="$(BaseOutputPath)$(Configuration)\x86\wixnative.exe" CopyToOutputDirectory="PreserveNewest" Condition=" '$(RuntimeIdentifier)'=='win-x86' " />
13 </ItemGroup>
14
15 <ItemGroup Condition=" '$(RequiresNativeWixAssets)'=='true' and '$(TargetFrameworkIdentifier)'!='.NETFramework' and '$(RuntimeIdentifier)'=='' ">
16 <NativeLibrary Include="$(MSBuildThisFileDirectory)wixnative\ARM64\mergemod.dll" RuntimeIdentifier="win-arm64" />
17 <NativeLibrary Include="$(MSBuildThisFileDirectory)wixnative\x64\mergemod.dll" RuntimeIdentifier="win-x64" />
18 <NativeLibrary Include="$(MSBuildThisFileDirectory)wixnative\Win32\mergemod.dll" RuntimeIdentifier="win-x86" />
19 <NativeLibrary Include="$(BaseOutputPath)$(Configuration)\ARM64\wixnative.exe" RuntimeIdentifier="win-arm64" />
20 <NativeLibrary Include="$(BaseOutputPath)$(Configuration)\x64\wixnative.exe" RuntimeIdentifier="win-x64" />
21 <NativeLibrary Include="$(BaseOutputPath)$(Configuration)\x86\wixnative.exe" RuntimeIdentifier="win-x86" />
22
23 <!--
24 This PackageReference is required so the RuntimeTargetsCopyLocalItems have a package (any package would
25 do, WixToolset.Data is as good as any) to "attach" themselves to.
26 -->
27 <PackageReference Include="WixToolset.Data" />
28
29 <RuntimeTargetsCopyLocalItems Include="@(NativeLibrary)"
30 AssetType="native"
31 DestinationSubDirectory="runtimes\%(RuntimeIdentifier)\native\"
32 NuGetPackageId="WixToolset.Data"
33 RuntimeIdentifier="%(RuntimeIdentifier)"
34 />
35 <None Include="@(RuntimeTargetsCopyLocalItems)"
36 Link="%(DestinationSubDirectory)\%(FileName)%(Extension)"
37 CopyToOutputDirectory="PreserveNewest" />
38 </ItemGroup>
39</Project>
diff --git a/src/wix/test/WixToolsetTest.BuildTasks/WixToolsetTest.BuildTasks.csproj b/src/wix/test/WixToolsetTest.BuildTasks/WixToolsetTest.BuildTasks.csproj
index 936fa4b9..4ae0f4a8 100644
--- a/src/wix/test/WixToolsetTest.BuildTasks/WixToolsetTest.BuildTasks.csproj
+++ b/src/wix/test/WixToolsetTest.BuildTasks/WixToolsetTest.BuildTasks.csproj
@@ -8,6 +8,7 @@
8 <DebugType>embedded</DebugType> 8 <DebugType>embedded</DebugType>
9 <RuntimeIdentifier>win-x64</RuntimeIdentifier> 9 <RuntimeIdentifier>win-x64</RuntimeIdentifier>
10 <SignOutput>false</SignOutput> 10 <SignOutput>false</SignOutput>
11 <RequiresNativeWixAssets>true</RequiresNativeWixAssets>
11 </PropertyGroup> 12 </PropertyGroup>
12 13
13 <ItemGroup> 14 <ItemGroup>
@@ -22,12 +23,6 @@
22 <ProjectReference Include="..\..\WixToolset.Core.TestPackage\WixToolset.Core.TestPackage.csproj" /> 23 <ProjectReference Include="..\..\WixToolset.Core.TestPackage\WixToolset.Core.TestPackage.csproj" />
23 </ItemGroup> 24 </ItemGroup>
24 25
25 <!-- Copy the x64 binaries for unittests since we've standardized on VS2022 (which is 64-bit only) -->
26 <ItemGroup>
27 <None Include="..\..\wixnative\x64\mergemod.dll" CopyToOutputDirectory="PreserveNewest" />
28 <None Include="$(BaseOutputPath)$(Configuration)\x64\wixnative.exe" CopyToOutputDirectory="PreserveNewest" />
29 </ItemGroup>
30
31 <ItemGroup> 26 <ItemGroup>
32 <PackageReference Include="Microsoft.Build.Tasks.Core" /> 27 <PackageReference Include="Microsoft.Build.Tasks.Core" />
33 <PackageReference Include="WixBuildTools.TestSupport" /> 28 <PackageReference Include="WixBuildTools.TestSupport" />
diff --git a/src/wix/test/WixToolsetTest.Core.Native/WixToolsetTest.Core.Native.csproj b/src/wix/test/WixToolsetTest.Core.Native/WixToolsetTest.Core.Native.csproj
index 44772187..66273be7 100644
--- a/src/wix/test/WixToolsetTest.Core.Native/WixToolsetTest.Core.Native.csproj
+++ b/src/wix/test/WixToolsetTest.Core.Native/WixToolsetTest.Core.Native.csproj
@@ -7,18 +7,13 @@
7 <IsPackable>false</IsPackable> 7 <IsPackable>false</IsPackable>
8 <RuntimeIdentifier>win-x64</RuntimeIdentifier> 8 <RuntimeIdentifier>win-x64</RuntimeIdentifier>
9 <SignOutput>false</SignOutput> 9 <SignOutput>false</SignOutput>
10 <RequiresNativeWixAssets>true</RequiresNativeWixAssets>
10 </PropertyGroup> 11 </PropertyGroup>
11 12
12 <ItemGroup> 13 <ItemGroup>
13 <Content Include="TestData\**" CopyToOutputDirectory="PreserveNewest" /> 14 <Content Include="TestData\**" CopyToOutputDirectory="PreserveNewest" />
14 </ItemGroup> 15 </ItemGroup>
15 16
16 <!-- Copy the x64 binaries for unittests since we've standardized on VS2022 (which is 64-bit only) -->
17 <ItemGroup>
18 <None Include="..\..\wixnative\x64\mergemod.dll" CopyToOutputDirectory="PreserveNewest" />
19 <None Include="$(BaseOutputPath)$(Configuration)\x64\wixnative.exe" CopyToOutputDirectory="PreserveNewest" />
20 </ItemGroup>
21
22 <ItemGroup> 17 <ItemGroup>
23 <ProjectReference Include="..\..\WixToolset.Core.Native\WixToolset.Core.Native.csproj" /> 18 <ProjectReference Include="..\..\WixToolset.Core.Native\WixToolset.Core.Native.csproj" />
24 </ItemGroup> 19 </ItemGroup>
diff --git a/src/wix/test/WixToolsetTest.CoreIntegration/WixToolsetTest.CoreIntegration.csproj b/src/wix/test/WixToolsetTest.CoreIntegration/WixToolsetTest.CoreIntegration.csproj
index b84b1ed3..996858d1 100644
--- a/src/wix/test/WixToolsetTest.CoreIntegration/WixToolsetTest.CoreIntegration.csproj
+++ b/src/wix/test/WixToolsetTest.CoreIntegration/WixToolsetTest.CoreIntegration.csproj
@@ -7,18 +7,13 @@
7 <IsPackable>false</IsPackable> 7 <IsPackable>false</IsPackable>
8 <DebugType>embedded</DebugType> 8 <DebugType>embedded</DebugType>
9 <SignOutput>false</SignOutput> 9 <SignOutput>false</SignOutput>
10 <RequiresNativeWixAssets>true</RequiresNativeWixAssets>
10 </PropertyGroup> 11 </PropertyGroup>
11 12
12 <ItemGroup> 13 <ItemGroup>
13 <Content Include="TestData\**" CopyToOutputDirectory="PreserveNewest" /> 14 <Content Include="TestData\**" CopyToOutputDirectory="PreserveNewest" />
14 </ItemGroup> 15 </ItemGroup>
15 16
16 <!-- Copy the x64 binaries for unittests since we've standardized on VS2022 (which is 64-bit only) -->
17 <ItemGroup>
18 <None Include="..\..\wixnative\x64\mergemod.dll" CopyToOutputDirectory="PreserveNewest" />
19 <None Include="$(BaseOutputPath)$(Configuration)\x64\wixnative.exe" CopyToOutputDirectory="PreserveNewest" />
20 </ItemGroup>
21
22 <ItemGroup> 17 <ItemGroup>
23 <ProjectReference Include="..\..\WixToolset.Core\WixToolset.Core.csproj" /> 18 <ProjectReference Include="..\..\WixToolset.Core\WixToolset.Core.csproj" />
24 <ProjectReference Include="..\..\WixToolset.Core.Burn\WixToolset.Core.Burn.csproj" /> 19 <ProjectReference Include="..\..\WixToolset.Core.Burn\WixToolset.Core.Burn.csproj" />
diff --git a/src/wix/test/WixToolsetTest.Sdk/WixToolsetTest.Sdk.csproj b/src/wix/test/WixToolsetTest.Sdk/WixToolsetTest.Sdk.csproj
index 44999f3d..5a6f6ad1 100644
--- a/src/wix/test/WixToolsetTest.Sdk/WixToolsetTest.Sdk.csproj
+++ b/src/wix/test/WixToolsetTest.Sdk/WixToolsetTest.Sdk.csproj
@@ -8,18 +8,13 @@
8 <DebugType>embedded</DebugType> 8 <DebugType>embedded</DebugType>
9 <DefaultItemExcludes>TestData\**;$(DefaultItemExcludes)</DefaultItemExcludes> 9 <DefaultItemExcludes>TestData\**;$(DefaultItemExcludes)</DefaultItemExcludes>
10 <SignOutput>false</SignOutput> 10 <SignOutput>false</SignOutput>
11 <RequiresNativeWixAssets>true</RequiresNativeWixAssets>
11 </PropertyGroup> 12 </PropertyGroup>
12 13
13 <ItemGroup> 14 <ItemGroup>
14 <Content Include="TestData\**" CopyToOutputDirectory="PreserveNewest" /> 15 <Content Include="TestData\**" CopyToOutputDirectory="PreserveNewest" />
15 </ItemGroup> 16 </ItemGroup>
16 17
17 <!-- Copy the x64 binaries for unittests since we've standardized on VS2022 (which is 64-bit only) -->
18 <ItemGroup>
19 <None Include="..\..\wixnative\x64\mergemod.dll" CopyToOutputDirectory="PreserveNewest" />
20 <None Include="$(BaseOutputPath)$(Configuration)\x64\wixnative.exe" CopyToOutputDirectory="PreserveNewest" />
21 </ItemGroup>
22
23 <ItemGroup> 18 <ItemGroup>
24 <ProjectReference Include="..\..\WixToolset.Core.TestPackage\WixToolset.Core.TestPackage.csproj" /> 19 <ProjectReference Include="..\..\WixToolset.Core.TestPackage\WixToolset.Core.TestPackage.csproj" />
25 </ItemGroup> 20 </ItemGroup>
diff --git a/src/wix/wix/wix.csproj b/src/wix/wix/wix.csproj
index a7df91f6..ec583475 100644
--- a/src/wix/wix/wix.csproj
+++ b/src/wix/wix/wix.csproj
@@ -14,6 +14,7 @@
14 <ApplicationManifest>wix.exe.manifest</ApplicationManifest> 14 <ApplicationManifest>wix.exe.manifest</ApplicationManifest>
15 <RollForward>Major</RollForward> 15 <RollForward>Major</RollForward>
16 <NuspecBasePath>$(OutputPath)publish\wix\</NuspecBasePath> 16 <NuspecBasePath>$(OutputPath)publish\wix\</NuspecBasePath>
17 <RequiresNativeWixAssets Condition=" '$(NCrunch)'=='' ">true</RequiresNativeWixAssets>
17 </PropertyGroup> 18 </PropertyGroup>
18 19
19 <ItemGroup> 20 <ItemGroup>
@@ -24,38 +25,4 @@
24 <ProjectReference Include="..\WixToolset.Core.WindowsInstaller\WixToolset.Core.WindowsInstaller.csproj" /> 25 <ProjectReference Include="..\WixToolset.Core.WindowsInstaller\WixToolset.Core.WindowsInstaller.csproj" />
25 </ItemGroup> 26 </ItemGroup>
26 27
27 <ItemGroup Condition=" '$(TargetFrameworkIdentifier)'=='.NETFramework' and '$(NCrunch)'=='' ">
28 <!-- Copy the x64 binaries when there is no RuntimeIdentifier since we've standardized on VS2022 (which is 64-bit only) -->
29 <None Include="..\wixnative\x64\mergemod.dll" CopyToOutputDirectory="PreserveNewest" Condition=" '$(RuntimeIdentifier)'=='win-x64' or '$(RuntimeIdentifier)'=='' " />
30 <None Include="$(BaseOutputPath)$(Configuration)\x64\wixnative.exe" CopyToOutputDirectory="PreserveNewest" Condition=" '$(RuntimeIdentifier)'=='win-x64' or '$(RuntimeIdentifier)'=='' " />
31
32 <None Include="..\wixnative\Win32\mergemod.dll" CopyToOutputDirectory="PreserveNewest" Condition=" '$(RuntimeIdentifier)'=='win-x86' " />
33 <None Include="$(BaseOutputPath)$(Configuration)\x86\wixnative.exe" CopyToOutputDirectory="PreserveNewest" Condition=" '$(RuntimeIdentifier)'=='win-x86' " />
34 </ItemGroup>
35
36 <ItemGroup Condition=" '$(TargetFrameworkIdentifier)'!='.NETFramework' and '$(NCrunch)'=='' ">
37 <NativeLibrary Include="..\wixnative\ARM64\mergemod.dll" RuntimeIdentifier="win-arm64" />
38 <NativeLibrary Include="..\wixnative\x64\mergemod.dll" RuntimeIdentifier="win-x64" />
39 <NativeLibrary Include="..\wixnative\Win32\mergemod.dll" RuntimeIdentifier="win-x86" />
40 <NativeLibrary Include="$(BaseOutputPath)$(Configuration)\ARM64\wixnative.exe" RuntimeIdentifier="win-arm64" />
41 <NativeLibrary Include="$(BaseOutputPath)$(Configuration)\x64\wixnative.exe" RuntimeIdentifier="win-x64" />
42 <NativeLibrary Include="$(BaseOutputPath)$(Configuration)\x86\wixnative.exe" RuntimeIdentifier="win-x86" />
43
44 <!--
45 This PackageReference is required so the RuntimeTargetsCopyLocalItems have a package (any package would
46 do, WixToolset.Data is as good as any) to "attach" themselves to.
47 -->
48 <PackageReference Include="WixToolset.Data" />
49
50 <RuntimeTargetsCopyLocalItems Include="@(NativeLibrary)"
51 AssetType="native"
52 DestinationSubDirectory="runtimes\%(RuntimeIdentifier)\native\"
53 NuGetPackageId="WixToolset.Data"
54 RuntimeIdentifier="%(RuntimeIdentifier)"
55 />
56 <None Include="@(RuntimeTargetsCopyLocalItems)"
57 Link="%(DestinationSubDirectory)\%(FileName)%(Extension)"
58 CopyToOutputDirectory="PreserveNewest" />
59 </ItemGroup>
60
61</Project> 28</Project>