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

Prevent --output command-line option for multi-targeted projects #13369

Open
dsplaisted opened this issue Sep 3, 2020 · 4 comments
Open

Prevent --output command-line option for multi-targeted projects #13369

dsplaisted opened this issue Sep 3, 2020 · 4 comments

Comments

@dsplaisted
Copy link
Member

For a multi-targeted build, the --output command-line option will cause the builds for multiple target frameworks to go to the same output path. This will likely cause a build failure due to files being in use, or an incorrect build output. See #13359.

We should do something to avoid this pit of failure. Some possibilities:

  • Generate a build error saying this isn't supported
  • Automatically append the TargetFramework to the specified output path
  • ???
@dsplaisted
Copy link
Member Author

Also related (to some degree): dotnet/msbuild#5420

@dsplaisted
Copy link
Member Author

Related / Dupe: #8964

@Forgind
Copy link
Member

Forgind commented Apr 14, 2021

@dsplaisted, I closed the MSBuild issue for this with dotnet/msbuild#5675. Are you planning to make the PR for consuming this in the SDK, do you want me to, or was it already done, and I forgot?

@Nirmal4G
Copy link
Contributor

Nirmal4G commented Jul 7, 2022

See #8964 (comment)

My preferred solution would be that we map BaseOutputPath to -o instead of OutputPath for both legacy and Sdk-style projects. With BaseOutputPath (dotnet/msbuild#5238) support added to Common targets, we could just do that.

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

No branches or pull requests

3 participants