Repository: godot
Issue: godot crashs when using snap installed dotnet
Labels: bug,platform:linuxbsd,topic:dotnet,crash

### Godot version

v4.0.2.stable.mono.official.7a0977ce2

### System information

Linux pop-os 6.2.6-76060206-generic #202303130630~1679424972~22.04~4a8cde1 SMP PREEMPT_DYNAMIC Tue M x86_64 x86_64 x86_64 GNU/Linux

### Issue description

# Use snap to install dotnet, crashs

```bash
sudo snap install dotnet-sdk --classic
```

As I found, when I install dotnet by `snap`, dotnet will be in  `/snap/bin/dotnet` 

But godot can't get started, it shows errors:
```bash
(base) yingshaoxo@pop-os:~/Documents/Godot_v4.0.2-stable_mono_linux_x86_64$ OpenGL API 4.6 (Core Profile) Mesa 22.3.5 - Compatibility - Using Device: Intel - Mesa Intel(R) UHD Graphics (TGL GT1)
 
ERROR: The host fxr folder does not exist: /usr/share/dotnet/host/fxr
   at: try_get_path_from_dotnet_root (modules/mono/editor/hostfxr_resolver.cpp:323)
ERROR: .NET: One of the dependent libraries is missing. Typically when the `hostfxr`, `hostpolicy` or `coreclr` dynamic libraries are not present in the expected locations.
   at: find_hostfxr (modules/mono/mono_gd/gd_mono.cpp:126)
/usr/bin/zenity: symbol lookup error: /lib/x86_64-linux-gnu/libwebkit2gtk-4.0.so.37: undefined symbol: gst_codec_utils_caps_get_mime_codec
ERROR: .NET: Failed to load hostfxr
   at: initialize (modules/mono/mono_gd/gd_mono.cpp:405)
WARNING: Blend file import is enabled in the project settings, but no Blender path is configured in the editor settings. Blend files will not be imported.
     at: _editor_init (modules/gltf/register_types.cpp:70)

================================================================
handle_crash: Program crashed with signal 11
Engine version: Godot Engine v4.0.2.stable.mono.official (7a0977ce2c558fe6219f0a14f8bd4d05aea8f019)
Dumping the backtrace. Please include this when reporting the bug to the project developer.
[1] /lib/x86_64-linux-gnu/libc.so.6(+0x42520) [0x7fa0e5042520] (??:0)
-- END OF BACKTRACE --
================================================================
```

___

# Use microsoft script to install dotnet, works fine

```bash
wget https://dot.net/v1/dotnet-install.sh -O dotnet-install.sh
chmod 777 dotnet-install.sh 
./dotnet-install.sh --channel 7.0

export PATH="$PATH:$HOME/.dotnet"
```

But if I install with `microsoft script`, dotnet will be in `~/.dotnet/dotnet`

**No crashs.**

logs:
```bash
(base) yingshaoxo@pop-os:~/Documents/Godot_v4.0.2-stable_mono_linux_x86_64$ ./Godot_v4.0.2-stable_mono_linux.x86_64 
Godot Engine v4.0.2.stable.mono.official.7a0977ce2 - https://godotengine.org
xkbcommon: ERROR: failed to add default include path /home/yingshaoxo/anaconda3/share/X11/xkb
OpenGL API 4.6 (Core Profile) Mesa 22.3.5 - Compatibility - Using Device: Intel - Mesa Intel(R) UHD Graphics (TGL GT1)
 
ERROR: The host fxr folder does not exist: /usr/share/dotnet/host/fxr
   at: try_get_path_from_dotnet_root (modules/mono/editor/hostfxr_resolver.cpp:323)
Editing project: /home/yingshaoxo/CS/test/godot_test
Godot Engine v4.0.2.stable.mono.official.7a0977ce2 - https://godotengine.org
xkbcommon: ERROR: failed to add default include path /home/yingshaoxo/anaconda3/share/X11/xkb
(base) yingshaoxo@pop-os:~/Documents/Godot_v4.0.2-stable_mono_linux_x86_64$ OpenGL API 4.6 (Core Profile) Mesa 22.3.5 - Compatibility - Using Device: Intel - Mesa Intel(R) UHD Graphics (TGL GT1)
 
ERROR: The host fxr folder does not exist: /usr/share/dotnet/host/fxr
   at: try_get_path_from_dotnet_root (modules/mono/editor/hostfxr_resolver.cpp:323)
WARNING: Blend file import is enabled in the project settings, but no Blender path is configured in the editor settings. Blend files will not be imported.
     at: _editor_init (modules/gltf/register_types.cpp:70)
``` 

### Steps to reproduce

See Issue description.

### Minimal reproduction project

No need.