You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hey, I've added all the packages listed, but still running anything with dotnet aspnet-codegenerator, even just -h, gives the error:
A fatal error occurred. The required library libhostfxr.so could not be found.
If this is a self-contained application, that library should exist in [/home/usr/.dotnet/tools/.store/dotnet-aspnet-codegenerator/5.0.2/dotnet-aspnet-codegenerator/5.0.2/tools/net5.0/any/].
I'm working via the command line on Linux Mint, 5.4.0-52-generic, dotnet 5.0.300 installed via the dotnet-install.sh file currently given on the Install ASP.NET Core page on Jun 6 2021.
EDIT:
Fixed it.
From grantzvolsky at dotnet/sdk#9304
Put the following in a bash file and run it as source:
run this every time you open a new terminal as:
. ~whatever-path/new.sh or source ~whatever-path/new.sh
Rick-Anderson
changed the title
Linux dotnet sdk error
Linux dotnet sdk error A fatal error occurred. The required library libhostfxr.so could not be found.
Jun 7, 2021
Hey, I've added all the packages listed, but still running anything with dotnet aspnet-codegenerator, even just -h, gives the error:
A fatal error occurred. The required library libhostfxr.so could not be found.
If this is a self-contained application, that library should exist in [/home/usr/.dotnet/tools/.store/dotnet-aspnet-codegenerator/5.0.2/dotnet-aspnet-codegenerator/5.0.2/tools/net5.0/any/].
I'm working via the command line on Linux Mint, 5.4.0-52-generic, dotnet 5.0.300 installed via the dotnet-install.sh file currently given on the Install ASP.NET Core page on Jun 6 2021.
EDIT:
Fixed it.
From grantzvolsky at dotnet/sdk#9304
Put the following in a bash file and run it as source:
run this every time you open a new terminal as:
. ~whatever-path/new.sh or source ~whatever-path/new.sh
makes dotnet aspnet-codegenerator work
export DOTNET_ROOT=/snap/dotnet-sdk/current
export MSBuildSDKsPath=$DOTNET_ROOT/sdk/$(${DOTNET_ROOT}/dotnet --version)/Sdks
export PATH="${PATH}:${DOTNET_ROOT}"
export PATH="$PATH:$HOME/.dotnet/tools"
Document Details
⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.
The text was updated successfully, but these errors were encountered: