Populate reference Path before running Generating reference source#5419
Populate reference Path before running Generating reference source#5419Anipik merged 2 commits intodotnet:masterfrom Anipik:genapi
Conversation
| </ItemGroup> | ||
|
|
||
| <Target Name="GenerateReferenceAssemblySource" | ||
| DependsOnTargets="ResolveAssemblyReferences" |
There was a problem hiding this comment.
Do we need this? I would expect people needs to do a vertical build before running this target. You need the source assembly in order to generate a ref assembly.
There was a problem hiding this comment.
Actually we do need this, now I see that I was the one that suggested it 😄
cc: @ericstj ?
There was a problem hiding this comment.
we can avoid this like dotnet/runtime@b18753a#diff-037531bd6f403e414dc011246d42d393R115
not sure if thats the correct way
There was a problem hiding this comment.
Yeah I was thinking about something similar as we only need ReferencePath for projects that have a ReferenceFromRuntime
There was a problem hiding this comment.
Double check that you don’t build ProjectReferences when calling this.
There was a problem hiding this comment.
... If you do, you can use CallTarget instead of DependsOnTargets and set the property which disables building the ProjectReference.
There was a problem hiding this comment.
i was not able to use callTarget because of this issue dotnet/msbuild#1006
There was a problem hiding this comment.
There are other options. What’s the experience right now? If I call This target what does it do WRT building ProjectReferences? (EG: we can call MSBuild on current project, ResolveReferences target passing BuildProjectReferences=false as global property, and get it's ouput)
There was a problem hiding this comment.
i am able to avoid this by 09b6f82#diff-154f708acf3f9e20aa7bc29fe50f4ff1R32
What’s the experience right now? If I call This target what does it do WRT building ProjectReferences?
It builds all the project references.
|
cc @ViktorHofer |
|
Would be nice to add tests at some point(tm) |
ViktorHofer
left a comment
There was a problem hiding this comment.
Approving assuming you validated the experience in dotnet runtime
Yes |
Related to dotnet/runtime#34604