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

[SBRP] Use GenAPI to generate the targeting packs #4965

Open
MichaelSimons opened this issue Mar 20, 2025 · 3 comments
Open

[SBRP] Use GenAPI to generate the targeting packs #4965

MichaelSimons opened this issue Mar 20, 2025 · 3 comments
Labels
area-sbrp Source build reference packages

Comments

@MichaelSimons
Copy link
Member

Currently the targeting packs are based on IL and utilize IlAsm/IlDasm for building/generating the source. In theory we could utilize GenAPI to generate the targeting packs into c# code.

There are unknowns if GenAPI is mature enough to handle shared framework assemblies. A POC would be needed to prove this out.

APICompat should help validate this change.

The benefits of this would be:

  1. Removing the IlAsm/IlDasm dependency. This adds additional bootstrap packages to the source build prep bootstrap process. e.g. this would help simplify the platform onboard process. This also unifies the build process between ref/targeting packs. Currently the targeting pack build infra is tied to Linux (see [SBRP] Support creating new reference packages from a Windows environment #3329)
  2. Consolidate the generate tooling to be based on one technology (e.g. GenAPI). Currently the targeting pack generator is not even in the public repo (see Move targeting package ILDasm tooling to public SBRP repo #3091)
@ViktorHofer
Copy link
Member

cc @ericstj @carlossanlop

@ericstj
Copy link
Member

ericstj commented Mar 21, 2025

Definitely support this. I suspect we might have a few issues, but I think both @carlossanlop and @marklio have been doing some work that does run GenAPI through most framework API and rooting those issues out to fix them. I bet we're pretty close to being able to do this.

@marklio
Copy link

marklio commented Mar 21, 2025

I did a proof of concept to use GenAPI to replace the old asmmeta system in .NET Framework builds. Once we were satisfied that the proof of concept was feasible, I set it aside to focus on some other priorities. I will probably jump back on that in the next couple of months, but would gladly partner on investments in this space. Our main hurdles were integration into NetFX-based MSBuild environmments and filtering types/members to deal with the cycles in NetFX assembly reference graphs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-sbrp Source build reference packages
Projects
Status: Backlog
Development

No branches or pull requests

4 participants