diff options
author | Sean Hall <r.sean.hall@gmail.com> | 2020-06-24 14:23:51 +1000 |
---|---|---|
committer | Sean Hall <r.sean.hall@gmail.com> | 2020-06-24 20:36:35 +1000 |
commit | c50a0e000ab1812ec4781ace349a5d84fa01c8e4 (patch) | |
tree | 22b8dbdb29113876a4e4d81585db9a796c5e3e37 /src | |
parent | d7bd6328ea9227f76b5337f703de9460a1738302 (diff) | |
download | wix-c50a0e000ab1812ec4781ace349a5d84fa01c8e4.tar.gz wix-c50a0e000ab1812ec4781ace349a5d84fa01c8e4.tar.bz2 wix-c50a0e000ab1812ec4781ace349a5d84fa01c8e4.zip |
Merge the native nupkg into the Core.Native nupkg.
There was no benefit in separating the native assets into its own package, the runtime.<rid>.PackageName strategy is for binaries to be copied to the root of project and therefore doesn't support the portable scenario where all available assets are required.
Manually author the repository element in the nupkg for SourceLink.
Diffstat (limited to 'src')
5 files changed, 33 insertions, 64 deletions
diff --git a/src/WixToolset.Core.Native/WixToolset.Core.Native.csproj b/src/WixToolset.Core.Native/WixToolset.Core.Native.csproj index ca8797a9..d12d0da6 100644 --- a/src/WixToolset.Core.Native/WixToolset.Core.Native.csproj +++ b/src/WixToolset.Core.Native/WixToolset.Core.Native.csproj | |||
@@ -5,10 +5,20 @@ | |||
5 | <NuspecFile>$(MSBuildThisFileName).nuspec</NuspecFile> | 5 | <NuspecFile>$(MSBuildThisFileName).nuspec</NuspecFile> |
6 | <Description>Core Native</Description> | 6 | <Description>Core Native</Description> |
7 | <DebugType>embedded</DebugType> | 7 | <DebugType>embedded</DebugType> |
8 | <!-- <BeforePack>SetNuspecProperties</BeforePack> --> | ||
9 | </PropertyGroup> | 8 | </PropertyGroup> |
10 | 9 | ||
11 | <ItemGroup> | 10 | <ItemGroup> |
11 | <ProjectReference Include="..\wixnative\wixnative.vcxproj"> | ||
12 | <PrivateAssets>All</PrivateAssets> | ||
13 | <Properties>Platform=Win32</Properties> | ||
14 | </ProjectReference> | ||
15 | <ProjectReference Include="..\wixnative\wixnative.vcxproj"> | ||
16 | <PrivateAssets>All</PrivateAssets> | ||
17 | <Properties>Platform=x64</Properties> | ||
18 | </ProjectReference> | ||
19 | </ItemGroup> | ||
20 | |||
21 | <ItemGroup> | ||
12 | <PackageReference Include="WixToolset.Data" Version="4.0.*" PrivateAssets="All" /> | 22 | <PackageReference Include="WixToolset.Data" Version="4.0.*" PrivateAssets="All" /> |
13 | </ItemGroup> | 23 | </ItemGroup> |
14 | 24 | ||
@@ -20,16 +30,16 @@ | |||
20 | <PropertyGroup> | 30 | <PropertyGroup> |
21 | <NativeFileListPath Condition=" '$(NCrunch)'=='' ">$(MSBuildProjectDir)..\..\build\obj\$(ProjectName)\$(Configuration)\NativeFileList.txt</NativeFileListPath> | 31 | <NativeFileListPath Condition=" '$(NCrunch)'=='' ">$(MSBuildProjectDir)..\..\build\obj\$(ProjectName)\$(Configuration)\NativeFileList.txt</NativeFileListPath> |
22 | <NativeFileListPath Condition=" '$(NCrunch)'=='1' ">$(NCrunchOriginalProjectDir)..\..\build\obj\$(ProjectName)\$(Configuration)\NativeFileList.txt</NativeFileListPath> | 32 | <NativeFileListPath Condition=" '$(NCrunch)'=='1' ">$(NCrunchOriginalProjectDir)..\..\build\obj\$(ProjectName)\$(Configuration)\NativeFileList.txt</NativeFileListPath> |
33 | <MergeModDirectory>$(MSBuildThisFileDirectory)..\wixnative\</MergeModDirectory> | ||
23 | </PropertyGroup> | 34 | </PropertyGroup> |
24 | 35 | ||
25 | <Target Name="BuildWixNative" BeforeTargets="GetCopyToOutputDirectoryItems" Condition=" '$(NCrunch)'=='' "> | 36 | <Target Name="BuildWixNative" BeforeTargets="GetCopyToOutputDirectoryItems" Condition=" '$(NCrunch)'=='' "> |
26 | <MSBuild Projects="..\wixnative\wixnative.vcxproj" Properties="Platform=Win32" Targets="Build;BuiltProjectOutputGroup;ContentFilesProjectOutputGroup;DebugSymbolsProjectOutputGroup"> | 37 | <ItemGroup> |
27 | <Output TaskParameter="TargetOutputs" ItemName="_NativeProjectOutput" /> | 38 | <_NativeProjectOutput Include="$(MergeModDirectory)x64\mergemod.dll" /> |
28 | </MSBuild> | 39 | <_NativeProjectOutput Include="$(OutputPath)..\x64\wixnative.exe" /> |
29 | <MSBuild Projects="..\wixnative\wixnative.vcxproj" Properties="Platform=x64" Targets="Build;BuiltProjectOutputGroup;ContentFilesProjectOutputGroup;DebugSymbolsProjectOutputGroup"> | 40 | <_NativeProjectOutput Include="$(OutputPath)..\x64\wixnative.pdb" /> |
30 | <Output TaskParameter="TargetOutputs" ItemName="_NativeProjectOutput" /> | 41 | </ItemGroup> |
31 | </MSBuild> | 42 | |
32 | |||
33 | <WriteLinesToFile File="$(NativeFileListPath)" Lines="@(_NativeProjectOutput)" Overwrite="true" /> | 43 | <WriteLinesToFile File="$(NativeFileListPath)" Lines="@(_NativeProjectOutput)" Overwrite="true" /> |
34 | 44 | ||
35 | <ItemGroup> | 45 | <ItemGroup> |
@@ -60,8 +70,8 @@ | |||
60 | 70 | ||
61 | <Target Name="SetNuspecProperties" AfterTargets="CoreBuild"> | 71 | <Target Name="SetNuspecProperties" AfterTargets="CoreBuild"> |
62 | <PropertyGroup> | 72 | <PropertyGroup> |
63 | <NuspecBasePath>$(OutputPath)</NuspecBasePath> | 73 | <NuspecBasePath>$(OutputPath)..\</NuspecBasePath> |
64 | <NuspecProperties>Configuration=$(Configuration);Id=$(MSBuildThisFileName);Version=$(BuildVersionSimple);Authors=$(Authors);Copyright=$(Copyright);Description=$(Description)</NuspecProperties> | 74 | <NuspecProperties>Id=$(MSBuildThisFileName);Version=$(BuildVersionSimple);Authors=$(Authors);Copyright=$(Copyright);Description=$(Description);RepositoryCommit=$(SourceRevisionId);RepositoryType=$(RepositoryType);RepositoryUrl=$(PrivateRepositoryUrl);MergeModDir=$(MergeModDirectory)</NuspecProperties> |
65 | </PropertyGroup> | 75 | </PropertyGroup> |
66 | </Target> | 76 | </Target> |
67 | </Project> | 77 | </Project> |
diff --git a/src/WixToolset.Core.Native/WixToolset.Core.Native.nuspec b/src/WixToolset.Core.Native/WixToolset.Core.Native.nuspec index 1ff5538b..e862b1ba 100644 --- a/src/WixToolset.Core.Native/WixToolset.Core.Native.nuspec +++ b/src/WixToolset.Core.Native/WixToolset.Core.Native.nuspec | |||
@@ -5,30 +5,25 @@ | |||
5 | <version>$version$</version> | 5 | <version>$version$</version> |
6 | <authors>$authors$</authors> | 6 | <authors>$authors$</authors> |
7 | <owners>$authors$</owners> | 7 | <owners>$authors$</owners> |
8 | <!-- <license type="expression">MS-RL</license> --> | 8 | <license type="expression">MS-RL</license> |
9 | <licenseUrl>https://licenses.nuget.org/MS-RL</licenseUrl> | ||
10 | <projectUrl>https://github.com/wixtoolset/Core.Native</projectUrl> | 9 | <projectUrl>https://github.com/wixtoolset/Core.Native</projectUrl> |
11 | <requireLicenseAcceptance>false</requireLicenseAcceptance> | 10 | <requireLicenseAcceptance>false</requireLicenseAcceptance> |
12 | <description>$description$</description> | 11 | <description>$description$</description> |
13 | <copyright>$copyright$</copyright> | 12 | <copyright>$copyright$</copyright> |
14 | 13 | <repository type="$repositorytype$" url="$repositoryurl$" commit="$repositorycommit$" /> | |
15 | <dependencies> | 14 | <dependencies> |
16 | <dependency id="runtime.win.WixToolset.Core.Native" version="$version$" /> | 15 | <group targetFramework=".NETStandard2.0" /> |
17 | <!-- | ||
18 | <dependency id="runtime.win-x86.WixToolset.Core.Native" version="$version$" /> | ||
19 | <dependency id="runtime.win-x64.WixToolset.Core.Native" version="$version$" /> | ||
20 | --> | ||
21 | </dependencies> | 16 | </dependencies> |
22 | </metadata> | 17 | </metadata> |
23 | 18 | ||
24 | <files> | 19 | <files> |
25 | <file src="$id$.dll" target="lib\netstandard2.0" /> | 20 | <file src="netstandard2.0\$id$.dll" target="lib\netstandard2.0" /> |
26 | 21 | ||
27 | <!-- | 22 | <file src="$mergemoddir$Win32\mergemod.dll" target="runtimes\win-x86\native" /> |
28 | <file src="..\Win32\wixnative.x86.exe" target="lib\netstandard2.0" /> | 23 | <file src="Win32\wixnative.exe" target="runtimes\win-x86\native" /> |
29 | <file src="..\Win32\wixnative.x86.pdb" target="lib\netstandard2.0" /> | 24 | <file src="Win32\wixnative.pdb" target="runtimes\win-x86\native" /> |
30 | <file src="..\x64\wixnative.amd64.exe" target="lib\netstandard2.0" /> | 25 | <file src="$mergemoddir$x64\mergemod.dll" target="runtimes\win-x64\native" /> |
31 | <file src="..\x64\wixnative.amd64.pdb" target="lib\netstandard2.0" /> | 26 | <file src="x64\wixnative.exe" target="runtimes\win-x64\native" /> |
32 | --> | 27 | <file src="x64\wixnative.pdb" target="runtimes\win-x64\native" /> |
33 | </files> | 28 | </files> |
34 | </package> | 29 | </package> |
diff --git a/src/test/WixToolsetTest.Core.Native/WixToolsetTest.Core.Native.csproj b/src/test/WixToolsetTest.Core.Native/WixToolsetTest.Core.Native.csproj index 14928112..9c493d84 100644 --- a/src/test/WixToolsetTest.Core.Native/WixToolsetTest.Core.Native.csproj +++ b/src/test/WixToolsetTest.Core.Native/WixToolsetTest.Core.Native.csproj | |||
@@ -3,8 +3,9 @@ | |||
3 | 3 | ||
4 | <Project Sdk="Microsoft.NET.Sdk"> | 4 | <Project Sdk="Microsoft.NET.Sdk"> |
5 | <PropertyGroup> | 5 | <PropertyGroup> |
6 | <TargetFramework>netcoreapp2.1</TargetFramework> | 6 | <TargetFramework>netcoreapp3.1</TargetFramework> |
7 | <IsPackable>false</IsPackable> | 7 | <IsPackable>false</IsPackable> |
8 | <RuntimeIdentifier>win-x64</RuntimeIdentifier> | ||
8 | </PropertyGroup> | 9 | </PropertyGroup> |
9 | 10 | ||
10 | <ItemGroup> | 11 | <ItemGroup> |
@@ -21,7 +22,7 @@ | |||
21 | </ItemGroup> | 22 | </ItemGroup> |
22 | 23 | ||
23 | <ItemGroup> | 24 | <ItemGroup> |
24 | <PackageReference Include="Microsoft.NET.Test.Sdk" Version="15.8.0" /> | 25 | <PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.3.0" /> |
25 | <PackageReference Include="xunit" Version="2.4.1" /> | 26 | <PackageReference Include="xunit" Version="2.4.1" /> |
26 | <PackageReference Include="xunit.runner.visualstudio" Version="2.4.1" PrivateAssets="All" /> | 27 | <PackageReference Include="xunit.runner.visualstudio" Version="2.4.1" PrivateAssets="All" /> |
27 | </ItemGroup> | 28 | </ItemGroup> |
diff --git a/src/wixnative/runtime.win.WixToolset.Core.Native.nuspec b/src/wixnative/runtime.win.WixToolset.Core.Native.nuspec deleted file mode 100644 index a775b570..00000000 --- a/src/wixnative/runtime.win.WixToolset.Core.Native.nuspec +++ /dev/null | |||
@@ -1,24 +0,0 @@ | |||
1 | <?xml version="1.0"?> | ||
2 | <package xmlns="http://schemas.microsoft.com/packaging/2010/07/nuspec.xsd"> | ||
3 | <metadata minClientVersion="4.0"> | ||
4 | <id>$id$</id> | ||
5 | <version>$version$</version> | ||
6 | <authors>$authors$</authors> | ||
7 | <owners>$authors$</owners> | ||
8 | <!-- <license type="expression">MS-RL</license> --> | ||
9 | <licenseUrl>https://licenses.nuget.org/MS-RL</licenseUrl> | ||
10 | <projectUrl>https://github.com/wixtoolset/Core.Native</projectUrl> | ||
11 | <requireLicenseAcceptance>false</requireLicenseAcceptance> | ||
12 | <description>$description$</description> | ||
13 | <copyright>$copyright$</copyright> | ||
14 | </metadata> | ||
15 | |||
16 | <files> | ||
17 | <file src="Win32\mergemod.dll" target="runtimes\win-x86\native" /> | ||
18 | <file src="Win32\wixnative.exe" target="runtimes\win-x86\native" /> | ||
19 | <file src="Win32\wixnative.pdb" target="runtimes\win-x86\native" /> | ||
20 | <file src="x64\mergemod.dll" target="runtimes\win-x64\native" /> | ||
21 | <file src="x64\wixnative.exe" target="runtimes\win-x64\native" /> | ||
22 | <file src="x64\wixnative.pdb" target="runtimes\win-x64\native" /> | ||
23 | </files> | ||
24 | </package> | ||
diff --git a/src/wixnative/wixnative.vcxproj b/src/wixnative/wixnative.vcxproj index 5927c14c..e53af651 100644 --- a/src/wixnative/wixnative.vcxproj +++ b/src/wixnative/wixnative.vcxproj | |||
@@ -30,7 +30,6 @@ | |||
30 | <TargetName>wixnative</TargetName> | 30 | <TargetName>wixnative</TargetName> |
31 | <PlatformToolset>v141</PlatformToolset> | 31 | <PlatformToolset>v141</PlatformToolset> |
32 | <CharacterSet>Unicode</CharacterSet> | 32 | <CharacterSet>Unicode</CharacterSet> |
33 | <Description>Native component of WixToolset.Core</Description> | ||
34 | </PropertyGroup> | 33 | </PropertyGroup> |
35 | 34 | ||
36 | <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" /> | 35 | <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" /> |
@@ -69,18 +68,6 @@ | |||
69 | <None Include="packages.config" /> | 68 | <None Include="packages.config" /> |
70 | </ItemGroup> | 69 | </ItemGroup> |
71 | 70 | ||
72 | <ItemGroup> | ||
73 | <None Include="$(Platform)\mergemod.dll"> | ||
74 | <DeploymentContent>true</DeploymentContent> | ||
75 | <Link>%(Filename)%(Extension)</Link> | ||
76 | <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory> | ||
77 | </None> | ||
78 | </ItemGroup> | ||
79 | |||
80 | <Target Name="Pack" DependsOnTargets="GetBuildVersion"> | ||
81 | <Exec Command='nuget pack runtime.win.WixToolset.Core.Native.nuspec -BasePath "$(BaseOutputPath)$(Configuration)" -OutputDirectory "$(BaseOutputPath)$(Configuration)" -NoPackageAnalysis -Properties Configuration=$(Configuration);Id=runtime.win.WixToolset.Core.Native;Version="$(BuildVersionSimple)";Platform=$(PlatformTarget);Authors="$(Authors)";Copyright="$(Copyright)";Description="$(Description)";Title="$(Title)"' /> | ||
82 | </Target> | ||
83 | |||
84 | <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" /> | 71 | <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" /> |
85 | <Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild"> | 72 | <Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild"> |
86 | <PropertyGroup> | 73 | <PropertyGroup> |