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

Fix Profiles Attributes for Ref/Runtime Pack #4788

Merged
merged 2 commits into from
Nov 22, 2024
Merged
Show file tree
Hide file tree
Changes from all 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
6 changes: 5 additions & 1 deletion src/windowsdesktop/src/sfx/Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,11 @@
<PackageReference Include="Microsoft.Internal.Runtime.WindowsDesktop.Transport" />
</ItemGroup>

<!-- Profile is intentionally undefined so that the reference will only be included when no profile is specified i.e. both WPF and WindowsForms are in use https://github.com/dotnet/wpf/blob/bbfc24fd13804a191e20064acd599b0a359092df/packaging/Microsoft.NET.Sdk.WindowsDesktop/targets/Microsoft.NET.Sdk.WindowsDesktop.props#L45-L46 -->
<ItemGroup>
<FrameworkListFileClass Include="WindowsFormsIntegration.dll" />
</ItemGroup>

<!-- References that are common to both WinForms and WPF -->
<ItemGroup>
<FrameworkListFileClass Include="Accessibility.dll" Profile="WindowsForms;WPF" />
Expand All @@ -56,7 +61,6 @@
<FrameworkListFileClass Include="System.Security.Permissions.dll" Profile="WindowsForms;WPF" />
<FrameworkListFileClass Include="System.Threading.AccessControl.dll" Profile="WindowsForms;WPF" />
<FrameworkListFileClass Include="System.Windows.Extensions.dll" Profile="WindowsForms;WPF" />
<FrameworkListFileClass Include="WindowsFormsIntegration.dll" Profile="WindowsForms;WPF"/>
</ItemGroup>

<!-- WPF specific references -->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,20 +9,14 @@
<RollForward>LatestPatch</RollForward>
</PropertyGroup>

<!-- Profile is intentionally undefined so that the reference will only be included when no profile is specified i.e. both WPF and WindowsForms are in use https://github.com/dotnet/wpf/blob/bbfc24fd13804a191e20064acd599b0a359092df/packaging/Microsoft.NET.Sdk.WindowsDesktop/targets/Microsoft.NET.Sdk.WindowsDesktop.props#L45-L46 -->
<ItemGroup>
<FrameworkListFileClass Include="WindowsFormsIntegration.resources.dll" />
lonitra marked this conversation as resolved.
Show resolved Hide resolved
lonitra marked this conversation as resolved.
Show resolved Hide resolved
</ItemGroup>

<!-- References that are common to both WinForms and WPF -->
<ItemGroup>
<FrameworkListFileClass Include="System.Diagnostics.EventLog.Messages.dll" Profile="WindowsForms;WPF" />
<FrameworkListFileClass Include="System.Xaml.resources.dll" Profile="WindowsForms;WPF" />
<FrameworkListFileClass Include="UIAutomationClient.resources.dll" Profile="WindowsForms;WPF" />
<FrameworkListFileClass Include="UIAutomationClientSideProviders.resources.dll" Profile="WindowsForms;WPF" />
<FrameworkListFileClass Include="UIAutomationProvider.resources.dll" Profile="WindowsForms;WPF" />
<FrameworkListFileClass Include="UIAutomationTypes.resources.dll" Profile="WindowsForms;WPF" />
<FrameworkListFileClass Include="WindowsBase.resources.dll" Profile="WindowsForms;WPF" />
<FrameworkListFileClass Include="WindowsFormsIntegration.resources.dll" Profile="WindowsForms;WPF" />
<FrameworkListFileClass Include="PenImc_cor3.dll" Profile="WindowsForms;WPF" />
<FrameworkListFileClass Include="vcruntime140_cor3.dll" Profile="WindowsForms;WPF" />
<FrameworkListFileClass Include="wpfgfx_cor3.dll" Profile="WindowsForms;WPF" />
<FrameworkListFileClass Condition="'$(PlatformTarget)' != 'ARM64'" Include="D3DCompiler_47_cor3.dll" Profile="WindowsForms;WPF" />
</ItemGroup>

<!-- Windows Forms specific references -->
Expand All @@ -41,24 +35,34 @@
<FrameworkListFileClass Include="System.Windows.Forms.Design.resources.dll" Profile="WindowsForms" />
<FrameworkListFileClass Include="System.Windows.Forms.Primitives.resources.dll" Profile="WindowsForms" />
<FrameworkListFileClass Include="System.Windows.Forms.resources.dll" Profile="WindowsForms" />
<FrameworkListFileClass Include="System.Windows.Input.Manipulations.resources.dll" Profile="WindowsForms" />
<FrameworkListFileClass Include="System.Private.Windows.Core.dll" Profile="WindowsForms" />
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As I noted in #4227 (review) this is the wrong way of doing this, Windows Forms owns the list, and it should be coming from dotnet/winforms instead of being manually maintained here.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, this is what #4796 describes. Currently https://github.com/dotnet/winforms/blob/main/pkg/Microsoft.Private.Winforms/sdk/dotnet-windowsdesktop/System.Windows.Forms.FileClassification.props is only for the ref pack, we'll need to make adjustments to have it also be used for the runtime pack here.

</ItemGroup>

<!-- WPF specific references -->
<ItemGroup>
<FrameworkListFileClass Condition="'$(PlatformTarget)' != 'ARM64'" Include="D3DCompiler_47_cor3.dll" Profile="WPF" />
<FrameworkListFileClass Include="DirectWriteForwarder.dll" Profile="WPF" />
<FrameworkListFileClass Include="PenImc_cor3.dll" Profile="WPF" />
<FrameworkListFileClass Include="PresentationCore.resources.dll" Profile="WPF" />
<FrameworkListFileClass Include="PresentationFramework.Fluent.dll" Profile="WPF" />
<FrameworkListFileClass Include="PresentationFramework.resources.dll" Profile="WPF" />
<FrameworkListFileClass Include="PresentationUI.resources.dll" Profile="WPF" />
<FrameworkListFileClass Include="ReachFramework.resources.dll" Profile="WPF" />
<FrameworkListFileClass Include="System.Windows.Controls.Ribbon.resources.dll" Profile="WPF" />
<FrameworkListFileClass Include="DirectWriteForwarder.dll" Profile="WPF" />
<FrameworkListFileClass Include="PresentationFramework-SystemCore.dll" Profile="WPF" />
<FrameworkListFileClass Include="PresentationFramework-SystemData.dll" Profile="WPF" />
<FrameworkListFileClass Include="PresentationFramework-SystemDrawing.dll" Profile="WPF" />
<FrameworkListFileClass Include="PresentationFramework-SystemXml.dll" Profile="WPF" />
<FrameworkListFileClass Include="PresentationFramework-SystemXmlLinq.dll" Profile="WPF" />
<FrameworkListFileClass Include="PresentationNative_cor3.dll" Profile="WPF" />
<FrameworkListFileClass Include="ReachFramework.resources.dll" Profile="WPF" />
<FrameworkListFileClass Include="System.Windows.Controls.Ribbon.resources.dll" Profile="WPF" />
<FrameworkListFileClass Include="System.Windows.Input.Manipulations.resources.dll" Profile="WPF" />
<FrameworkListFileClass Include="System.Xaml.resources.dll" Profile="WPF" />
<FrameworkListFileClass Include="UIAutomationClient.resources.dll" Profile="WPF" />
<FrameworkListFileClass Include="UIAutomationClientSideProviders.resources.dll" Profile="WPF" />
<FrameworkListFileClass Include="UIAutomationProvider.resources.dll" Profile="WPF" />
<FrameworkListFileClass Include="UIAutomationTypes.resources.dll" Profile="WPF" />
<FrameworkListFileClass Include="vcruntime140_cor3.dll" Profile="WPF" />
<FrameworkListFileClass Include="WindowsBase.resources.dll" Profile="WPF" />
<FrameworkListFileClass Include="wpfgfx_cor3.dll" Profile="WPF" />
</ItemGroup>
</Project>