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

Move generating implicit framework defines to a target. #45696

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

teo-tsirpanis
Copy link

This PR moves the logic that sets the implicit framework defines to the newly added GenerateTargetFrameworkDefineConstants target. Instead of directly modifying the DefineConstants property, this target modifies the _ImplicitDefineConstant item like the other targets do, which causes the defines to be set even if DefineConstants is specified as a global property. Language-specific logic was also deduplicated.

Fixes #45638. Validated locally by building the repro attached in the issue with a patched installation of the .NET SDK.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-NetSDK untriaged Request triage from a team member
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Inconcistent definition of implicit framework defines when using /p:DefineConstants.
1 participant