Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WPF support for ARM64: Enable build in public repo and update packaging #4048

Merged
merged 5 commits into from
Jan 22, 2021
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions Directory.Build.props
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
<Project>
<PropertyGroup>
<RepositoryName>wpf</RepositoryName>
<WindowsDesktopARM64Support>true</WindowsDesktopARM64Support>
</PropertyGroup>
<!-- Normalize $(TestWpfArcadeSdkPath) by appending a '\' to it if one is missing -->
<PropertyGroup Condition="'$(TestWpfArcadeSdkPath)'!=''">
Expand Down
19 changes: 9 additions & 10 deletions eng/copy-wpf.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,10 @@ Write-Host "Target architecture - configuration: " $arch $Config
function CopyBinariesToLocation($location)
{
$locallyBuiltBinaryLocationBase = Join-Path $RepoRoot "artifacts\packaging"

Write-Host "Copy native binaries..."
CopyNativeBinariesToLocation $location $locallyBuiltBinaryLocationBase
CopyNativeBinariesToLocation $location $locallyBuiltBinaryLocationBase

Write-Host "Copy managed binaries..."
CopyManagedBinariesToLocation $location $locallyBuiltBinaryLocationBase
}
Expand All @@ -58,7 +58,7 @@ function CopyNativeBinariesToLocation($location, $localBinLocation)
}
function CopyManagedBinariesToLocation($location, $localBinLocation)
{
# Layout of where the managed binaries looks something like this:
# Layout of where the managed binaries looks something like this:
# x86 - artifacts\packaging\Debug\Microsoft.DotNet.Wpf.GitHub\lib\net5.0
# x64 - artifacts\packaging\Debug\x64\Microsoft.DotNet.Wpf.GitHub\lib\net5.0

Expand Down Expand Up @@ -121,11 +121,11 @@ elseif($testhost)
}
else
{
$location = Resolve-Path (Join-Path $destination "shared\Microsoft.WindowsDesktop.App\$version")
$location = Resolve-Path (Join-Path $destination "shared\Microsoft.WindowsDesktop.App\$version")
}

Write-Host "Copying binaries to dotnet installation at $location"

if(![System.IO.Directory]::Exists($location))
{
Write-Host "Location unavailable: " $location -ForegroundColor Red
Expand All @@ -146,7 +146,7 @@ elseif($testhost)
Write-Host "** Setting $dotnetVariableToSet to $destination **"
Set-Item -Path $dotnetVariableToSet -Value $destination

Write-Host "** Setting env:DOTNET_MULTILEVEL_LOOKUP to 0 **"
Write-Host "** Setting env:DOTNET_MULTILEVEL_LOOKUP to 0 **"
$env:DOTNET_MULTILEVEL_LOOKUP=0
}
}
Expand All @@ -159,9 +159,8 @@ else
Write-Host "App publishing directory unavailable: " $location -ForegroundColor Red
return
}

Write-Host "App publishing directory: " $location
Write-Host "Copying binaries to app publishing directory..."
CopyBinariesToLocation $location
CopyBinariesToLocation $location
}

8 changes: 4 additions & 4 deletions eng/helixpublish.proj
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<!--
Ideally we could use $(MicrosoftNetCoreAppVersion) for DotNetCliVersion and 'runtime' for DotNetCliPackageType.
However, we need a full install on the Helix machine that includes the WindowsDesktop SDK since QV is dependent on it.
Once we move it into the open we can put these back to how they should be. See https://github.com/dotnet/wpf/issues/816
Once we move it into the open we can put these back to how they should be. See https://github.com/dotnet/wpf/issues/816
for any more details.

Right now, we set it to match global.json.tools.dotnet set by pre-build.ps1. Both of these can be removed once the above
Expand All @@ -29,11 +29,11 @@
</PropertyGroup>

<ItemGroup>
<HelixCorrelationPayload Include="$(ArtifactsDir)\test\$(Configuration)\$(Platform)" />
<HelixCorrelationPayload Include="$(ArtifactsDir)\test\$(Configuration)\$(Platform)" />
<HelixWorkItem Include="@(DRT)">
<Timeout>00:20:00</Timeout>
<Command>call %HELIX_CORRELATION_PAYLOAD%\runtests.cmd /Area=%(Area) -ci</Command>
</HelixWorkItem>

</ItemGroup>
</Project>
</Project>
9 changes: 9 additions & 0 deletions eng/pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,15 @@ jobs:
Build_Release_x64:
_BuildConfig: Release
_Platform: x64
${{ if eq(parameters.runAsPublic, 'true') }}:
Build_Debug_arm64:
_BuildConfig: Debug
# override some variables for debug
# _SignType has to be real for package publishing to succeed - do not override to test.
_Platform: arm64
Build_Release_arm64:
_BuildConfig: Release
_Platform: arm64
steps:
- checkout: self
clean: true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,20 +2,20 @@
<PropertyGroup>
<ProjectGuid>{B73BB4AB-68DE-4B91-BBB0-AB4F2D504AC3}</ProjectGuid>
<TargetFramework>net5.0</TargetFramework>
<Platforms>AnyCPU;x64</Platforms>
<Platforms>AnyCPU;x64;arm64</Platforms>
<!-- We ignore this warning because we want to pack powershell scripts that won't be executed as part of installing this package. -->
<NoWarn>$(NoWarn);NU5111</NoWarn>
</PropertyGroup>

<PropertyGroup>
<!--
<!--
PlatformIndependentPackage = true means that this package does
not require the automatic generation of a runtime.json file using
the Bait & Switch technique to reference RID specific packages
-->
<PlatformIndependentPackage>true</PlatformIndependentPackage>
</PropertyGroup>

<PropertyGroup>
<PackageName>$(MSBuildProjectName.Replace('.ArchNeutral',''))$(TransportPackageNameSuffix)</PackageName>
<AssemblyName>$(PackageName)</AssemblyName>
Expand All @@ -32,13 +32,13 @@
<PackagingContent Include="$(RepoRoot)eng\WpfArcadeSdk\tools\CodeAnalysis\*" SubFolder="root\tools\CodeAnalysis" />
</ItemGroup>

<!--
<!--
Pack $(WpfSharedDir) and $(WpfCommonDir) sources for use by dotnet-wpf-int
-->
<ItemGroup>
<PackagingContent Include="$(WpfSharedDir)**\*" SubFolder="root\Src\Shared\%(RecursiveDir)" />
<PackagingContent Include="$(WpfCommonDir)**\*" SubFolder="root\Src\Common\%(RecursiveDir)" />

<PackagingContent Include="$(WpfGraphicsDir)core\**\*.h*" SubFolder="root\Src\WpfGfx\core\%(RecursiveDir)" />
<PackagingContent Include="$(WpfGraphicsDir)core\**\*.inl" SubFolder="root\Src\WpfGfx\core\%(RecursiveDir)" />
<PackagingContent Include="$(WpfGraphicsDir)common\**\*.h*" SubFolder="root\Src\WpfGfx\common\%(RecursiveDir)" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@
<PropertyGroup>
<ProjectGuid>9a7e395b-e859-40e2-809d-efb72cf3a2ee</ProjectGuid>
<TargetFramework>net5.0</TargetFramework>
<Platforms>AnyCPU;x64</Platforms>
<Platforms>AnyCPU;x64;arm64</Platforms>
</PropertyGroup>

<PropertyGroup>
<PackageName>$(MSBuildProjectName.Replace('.ArchNeutral',''))$(TransportPackageNameSuffix)</PackageName>
<AssemblyName>$(PackageName)</AssemblyName>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<PropertyGroup>
<ProjectGuid>c847934a-828c-4ebb-a004-b0e97c8313f4</ProjectGuid>
<TargetFramework>net5.0</TargetFramework>
<Platforms>AnyCPU;x64</Platforms>
<Platforms>AnyCPU;x64;arm64</Platforms>
</PropertyGroup>

<PropertyGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,26 +2,26 @@
<PropertyGroup>
<ProjectGuid>{BFF6C118-3369-43B5-ACA6-D65ED00EEBE0}</ProjectGuid>
<TargetFramework>net5.0</TargetFramework>
<Platforms>AnyCPU;x64</Platforms>
<Platforms>AnyCPU;x64;arm64</Platforms>
</PropertyGroup>

<PropertyGroup>
<!--
<!--
PlatformIndependentPackage = true means that this package does
not require the automatic generation of a runtime.json file using
the Bait & Switch technique to reference RID specific packages
-->
<PlatformIndependentPackage>true</PlatformIndependentPackage>
</PropertyGroup>

<PropertyGroup>
<PackageName>$(MSBuildProjectName.Replace('.ArchNeutral',''))$(TransportPackageNameSuffix)</PackageName>
<AssemblyName>$(PackageName)</AssemblyName>
<PackageDescription>Project templates for .NET WPF Projects</PackageDescription>
</PropertyGroup>

<ItemGroup>
<PackagingContent Include="useSharedDesignerContext.txt" SubFolder="root" />
<PackagingContent Include="useSharedDesignerContext.txt" SubFolder="root" />
<PackagingContent Include="content\**\*" SubFolder="root\%(RecursiveDir)" />
</ItemGroup>
</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,18 @@
<PropertyGroup>
<ProjectGuid>{440d06b8-e3de-4c0d-ad25-cd4f43d836e1}</ProjectGuid>
<TargetFramework>net5.0</TargetFramework>
<Platforms>AnyCPU;x64</Platforms>
<Platforms>AnyCPU;x64;arm64</Platforms>
</PropertyGroup>

<PropertyGroup>
<!--
<!--
PlatformIndependentPackage = true means that this package does
not require the automatic generation of a runtime.json file using
the Bait & Switch technique to reference RID specific packages
-->
<PlatformIndependentPackage>true</PlatformIndependentPackage>
</PropertyGroup>

<PropertyGroup>
<PackageName>$(MSBuildProjectName.Replace('.ArchNeutral',''))$(TransportPackageNameSuffix)</PackageName>
<AssemblyName>$(PackageName)</AssemblyName>
Expand Down