Unable to build single file executable
Summary
When building and packaging for .net 5 and using single file and self contained flags, the path to the native vlc library cannot be resolved.
Minimal project and steps to reproduce
- Create any .net 5+ console application with LibVLCSharp nuget package installed
- In main call Core.Initialize()
- Build and publish the console app using single file and self contained options:
dotnet publish 'path/to.sln' -c release -r win-x64 --no-restore -p:PublishSingleFile=true --self-contained true -o 'build\win-x64'
- Run built executable
- See error
What is the current bug behavior?
What is the expected correct behavior?
Application should run with all dependencies built in, and resolve the correct path to the embedded libraries.
Does it work on other plaforms? Does it work with the official VLC apps?
no
Relevant logs and/or screenshots
Environment
- OS: windows 10
- Device: Windows 10 PC
- LibVLCSharp version 3.5.0