Linux does not come with the .NET runtime pre-installed.
If you have not installed it and you try to publish with
self-contained false, then you will get an error when you try and
run the executable. Something similar to this.
You must install .NET to run this
application.
App: /home/pcuser/helloworld/helloworld
Architecture: x64
App host version: 6.0.22
.NET location: Not found
Publishing with self-contained true is a good alternative if
your chosen runtime is not easily available on your distro. It
increases the output size by about 60 MB but provides a simple
solution.
Details of how to install the runtime may be found here.
If you are using .NET 6 you might need the following.
sudo apt update
sudo apt install dotnet-runtime-6.0
If you are using ABCChrome then you may need to install a few
extra packages.
# for Ubuntu 22 & 23
sudo apt install -y libasound2 libnss3 curl
# for Ubuntu 24
sudo apt install -y libasound2t64 libnss3 curl
# for Ubuntu 22 only - not needed on 23 and 24
sudo apt install -y xserver-xorg-core --no-install-recommends
--no-install-suggests
sudo apt install -y libcairo2 libatk1.0-0 libatk-bridge2.0-0
libcups2 libxcomposite1 libxdamage1 libxrandr2 libxkbcommon0
libpango-1.0-0
While ABCpdf does not officially support Fedora Linux, here are
the additional Fedora packages ABCChrome requires.
# for Fedora Linux 40
sudo dnf install -y alsa-lib mesa-libgbm cairo atk at-spi2-atk
cups-libs libXcomposite libXdamage libXrandr pango
|