Dynamically detect the RuntimeIdentifier #5

Open
opened 2026-01-29 16:27:04 +00:00 by claunia · 2 comments
Owner

Originally created by @qmfrederik on GitHub (Sep 26, 2017).

Currently we require everyone to specify the RuntimeIdentifier when creating, for example, RPM packages.

We do so because we currently create self-contained applications (SPAs) which include the .NET Core runtime. Additionally, projects may take on 3rd party dependencies which contain native code; we also need to make sure we include the native dependencies for the correct runtime.

We may be able to loosen the requirement somewhat, though. The .csproj file already contains a list of target runtimes. If there's only one target runtime, or only one target runtime that makes sense for the package format, we should be able to infer that one.

Originally created by @qmfrederik on GitHub (Sep 26, 2017). Currently we require everyone to specify the RuntimeIdentifier when creating, for example, RPM packages. We do so because we currently create self-contained applications (SPAs) which include the .NET Core runtime. Additionally, projects may take on 3rd party dependencies which contain native code; we also need to make sure we include the native dependencies for the correct runtime. We may be able to loosen the requirement somewhat, though. The `.csproj` file already contains a list of target runtimes. If there's only one target runtime, or only one target runtime that makes sense for the package format, we should be able to infer that one.
claunia added the up-for-grabs label 2026-01-29 16:27:04 +00:00
Author
Owner

@qmfrederik commented on GitHub (Sep 26, 2017):

/cc @tmds split off from #6

@qmfrederik commented on GitHub (Sep 26, 2017): /cc @tmds split off from #6
Author
Owner

@qmfrederik commented on GitHub (Nov 22, 2019):

With #125, you no longer need to specify a --runtime. The default runtime from the .csproj will be used. If no runtime is set, you'll end up with a framework-dependent package.

@qmfrederik commented on GitHub (Nov 22, 2019): With #125, you no longer need to specify a `--runtime`. The default runtime from the `.csproj` will be used. If no runtime is set, you'll end up with a framework-dependent package.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/dotnet-packaging#5