Closed
Description
For source-build we want to be able to build .NET using source-build on a system where the rid is not known to .NET.
We want this build to succeed, and the rid to be known to .NET.
For the build to succeed, we need to build using another rid which is known and compatible. I think this may be possible already (to some extent) by using the DOTNET_RUNTIME_ID envvar.
For the rid to be known to .NET, it needs to know its place in the graph.
Example pseudo build commands:
Build on Fedora 35 (rid derived from os-release is fedora.35):
./build.sh --build-rid linux --parent-rids fedora,linux
Build on RHEL 8 (rid derived from os-release is rhel.8):
./build.sh --build-rid linux --parent-rids linux
Build on CentOS 8 (rid derived from os-release is centos.8):
./build.sh --build-rid linux --parent-rids rhel.8,linux
Relates to NuGet/Home#5862, dotnet/source-build#297.