Skip to content

Define the managed dependencies of the crossgen-corelib.proj file through ProjectReferences#86735

Merged
jkoritzinsky merged 3 commits into
dotnet:mainfrom
jkoritzinsky:proj-ref-cgcorelib
May 25, 2023
Merged

Define the managed dependencies of the crossgen-corelib.proj file through ProjectReferences#86735
jkoritzinsky merged 3 commits into
dotnet:mainfrom
jkoritzinsky:proj-ref-cgcorelib

Conversation

@jkoritzinsky
Copy link
Copy Markdown
Member

Instead of having an implicit ordering, directly add ProjectReference dependencies here to make it possible to "dotnet build" this project to crossgen corelib.

This also fixes a long-standing bug from a clean build that you'd need to build clr.tools as dotnet-pgo wouldn't be built when just building clr.runtime+clr.corelib+clr.nativecorelib.

…ough ProjectReferences

Instead of having an implicit ordering, directly add ProjectReference dependencies here to make it possible to "dotnet build" this project to crossgen corelib.

This also fixes a long-standing bug from a clean build that you'd need to build clr.tools as dotnet-pgo wouldn't be built when just building clr.runtime+clr.corelib+clr.nativecorelib.
@jkoritzinsky jkoritzinsky added the area-Infrastructure-coreclr Only use for closed issues label May 24, 2023
@jkoritzinsky jkoritzinsky requested review from agocke and sbomer May 24, 2023 23:14
@ghost
Copy link
Copy Markdown

ghost commented May 24, 2023

Tagging subscribers to this area: @hoyosjs
See info in area-owners.md if you want to be subscribed.

Issue Details

Instead of having an implicit ordering, directly add ProjectReference dependencies here to make it possible to "dotnet build" this project to crossgen corelib.

This also fixes a long-standing bug from a clean build that you'd need to build clr.tools as dotnet-pgo wouldn't be built when just building clr.runtime+clr.corelib+clr.nativecorelib.

Author: jkoritzinsky
Assignees: -
Labels:

area-Infrastructure-coreclr

Milestone: -

@ghost ghost assigned jkoritzinsky May 24, 2023
Comment thread eng/Subsets.props
Comment on lines -360 to -362
<!-- Build crossgen2 that will be used to compile System.Private.CoreLib library for CoreCLR -->
<ProjectToBuild Condition="('$(CrossBuild)' == 'true' or '$(BuildArchitecture)' != '$(TargetArchitecture)') and '$(BuildArchitecture)' == 'x64'" Include="$(CoreClrProjectRoot)tools\aot\crossgen2\crossgen2_crossarch.csproj" Category="clr" />
<ProjectToBuild Condition="!(('$(CrossBuild)' == 'true' or '$(BuildArchitecture)' != '$(TargetArchitecture)') and '$(BuildArchitecture)' == 'x64')" Include="$(CoreClrProjectRoot)tools\aot\crossgen2\crossgen2.csproj" Category="clr" />
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

We don't need this anymore since we define this dependency through ProjectReferences now, which is nice.


<Copy Condition="!$(BuildDll)" SourceFiles="$(CoreLibInputPath)" DestinationFiles="$(CoreLibOutputPath)" UseHardlinksIfPossible="true" />

<Message Importance="High" Text="Crossgenning of System.Private.CoreLib succeeded. Finished at $(TIME)" />
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

TIME was never set, so I figured we might as well remove it.

Copy link
Copy Markdown
Member

@sbomer sbomer left a comment

Choose a reason for hiding this comment

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

Question about the build ordering, otherwise LGTM, thanks!

Comment thread src/coreclr/crossgen-corelib.proj
Comment thread src/coreclr/crossgen-corelib.proj Outdated
@jkoritzinsky
Copy link
Copy Markdown
Member Author

Failures are known

@jkoritzinsky jkoritzinsky merged commit 12f4ed6 into dotnet:main May 25, 2023
@jkoritzinsky jkoritzinsky deleted the proj-ref-cgcorelib branch May 25, 2023 22:38
@ghost ghost locked as resolved and limited conversation to collaborators Jun 25, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

area-Infrastructure-coreclr Only use for closed issues

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants