Skip to content

Remove GeneratedFilesOutputPath parameter from XamlPreCompile targets#12885

Merged
rainersigwald merged 4 commits intomainfrom
copilot/remove-generatedfilesoutputpath-parameter
Dec 16, 2025
Merged

Remove GeneratedFilesOutputPath parameter from XamlPreCompile targets#12885
rainersigwald merged 4 commits intomainfrom
copilot/remove-generatedfilesoutputpath-parameter

Conversation

Copy link
Contributor

Copilot AI commented Dec 5, 2025

Context

The XamlPreCompile targets in Microsoft.CSharp.CurrentVersion.targets and Microsoft.VisualBasic.CurrentVersion.targets were passing GeneratedFilesOutputPath to the Csc and Vbc tasks, which is unnecessary for XAML pre-compilation scenarios.

Changes Made

  • Removed GeneratedFilesOutputPath="$(CompilerGeneratedFilesOutputPath)" parameter from the Csc task invocation in the XamlPreCompile target in Microsoft.CSharp.CurrentVersion.targets
  • Removed GeneratedFilesOutputPath="$(CompilerGeneratedFilesOutputPath)" parameter from the Vbc task invocation in the XamlPreCompile target in Microsoft.VisualBasic.CurrentVersion.targets
  • Updated comments in both files to document that XamlPreCompile intentionally omits this parameter while remaining otherwise identical to CoreCompile

Testing

  • Full repository build succeeds
  • Sample projects build successfully with modified MSBuild

Notes

This intentionally diverges from the CoreCompile targets in Microsoft.CSharp.Core.targets and Microsoft.VisualBasic.Core.targets, which retain the GeneratedFilesOutputPath parameter. Both C# and VB implementations now have consistent changes.

Original prompt

On Microsoft.CSharp.CurrentVersion.targets, Remove the GeneratedFilesOutputPath parameter to the Csc task invocation in the XamlPreCompile target.


💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

@dotnet-policy-service
Copy link
Contributor

Hello @@copilot, I noticed that you’re changing an .swr file or any file under src/Package/MSBuild.VSSetup.. Please make sure to validate this change by an experimental VS insertion. This is accomplished by pushing to an exp/* branch, which requires write permissions to this repo.

Copilot AI changed the title [WIP] Remove GeneratedFilesOutputPath parameter from Csc task Remove GeneratedFilesOutputPath parameter from XamlPreCompile target Dec 5, 2025
Copilot AI requested a review from dsplaisted December 5, 2025 21:15
@dsplaisted dsplaisted marked this pull request as ready for review December 8, 2025 20:51
Copilot AI review requested due to automatic review settings December 8, 2025 20:51
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR removes the GeneratedFilesOutputPath parameter from the Csc task invocation in the XamlPreCompile target and updates the associated comment to document this intentional divergence from the CoreCompile target in Microsoft.CSharp.Core.targets.

Key changes:

  • Removed GeneratedFilesOutputPath="$(CompilerGeneratedFilesOutputPath)" parameter from Csc task in XamlPreCompile target
  • Updated comment to explicitly state that GeneratedFilesOutputPath is intentionally omitted

Copy link
Contributor Author

Copilot AI commented Dec 8, 2025

Just as a heads up, I was blocked by some firewall rules while working on your feedback. Expand below for details.

Warning

Firewall rules blocked me from connecting to one or more addresses (expand for details)

I tried to connect to the following addresses, but was blocked by firewall rules:

  • dnceng.pkgs.visualstudio.com
    • Triggering command: /home/REDACTED/work/msbuild/msbuild/artifacts/bin/bootstrap/core/dotnet dotnet build src/Samples/Dependency/Dependency.csproj (dns block)

If you need me to access, download, or install something from one of these locations, you can either:

Copilot AI changed the title Remove GeneratedFilesOutputPath parameter from XamlPreCompile target Remove GeneratedFilesOutputPath parameter from XamlPreCompile targets Dec 8, 2025
Copilot AI requested a review from rainersigwald December 8, 2025 21:17
@baronfel
Copy link
Member

@rainersigwald any reason to not merge this?

@rainersigwald
Copy link
Member

No, we should merge as soon as we have green perf ddrits again.

@rainersigwald rainersigwald self-assigned this Dec 15, 2025
@rainersigwald rainersigwald merged commit dc5088c into main Dec 16, 2025
10 checks passed
@rainersigwald rainersigwald deleted the copilot/remove-generatedfilesoutputpath-parameter branch December 16, 2025 15:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants