GenerateAdditionalSources target runs after MarkupCompile
- Dominant language
- C#
- Stars
- 5.5k
- Forks
- 1.5k
- Avg merge
- 1d 8h
- Merged PRs (30d)
- 141
Description
The `GenerateAdditionalSources` target is used to generate AssemblyAttributes like [AssemblyVersion]:
https://github.com/dotnet/msbuild/blob/40f49cd8d06ec3ed6933fa66183e8d1615cb2edc/src/Tasks/Microsoft.Common.CurrentVersion.targets#L3568
However it runs after MarkupCompile, and GenerateTemporaryTargetAssembly doesn't take it into account.
So at the time BAML is compiled, the default 0.0.0.0 version is being baked into BAML (since the temp assembly passed to MarkupCompilePass2 doesn't have the version set yet). This causes runtime exceptions.
We need to make sure that the files generated during the build are added to GenerateTemporaryTargetAssembly.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.