mesen: don't use absolute path for Exec in generated .desktop files

This commit is contained in:
TomaSajt 2025-08-08 13:39:04 +02:00
parent a2667c8258
commit b580ef2739
No known key found for this signature in database
GPG Key ID: F011163C050122A1
2 changed files with 15 additions and 0 deletions

View File

@ -0,0 +1,13 @@
diff --git a/UI/Config/FileAssociationHelper.cs b/UI/Config/FileAssociationHelper.cs
index bcd40ce..4965c7a 100644
--- a/UI/Config/FileAssociationHelper.cs
+++ b/UI/Config/FileAssociationHelper.cs
@@ -152,7 +152,7 @@ namespace Mesen.Config
"Comment=Emulator" + Environment.NewLine +
"Keywords=game;emulator;emu" + Environment.NewLine +
"Categories=GNOME;GTK;Game;Emulator;" + Environment.NewLine +
- "Exec=" + mainModule.FileName + " %f" + Environment.NewLine +
+ "Exec=" + "Mesen" + " %f" + Environment.NewLine +
"NoDisplay=false" + Environment.NewLine +
"StartupNotify=true" + Environment.NewLine +
"Icon=MesenIcon" + Environment.NewLine;

View File

@ -26,6 +26,8 @@ buildDotnetModule rec {
./dont-use-nightly-avalonia.patch
# upstream has a weird library loading mechanism, which we override with a more sane alternative
./dont-zip-libraries.patch
# without this the generated .desktop file uses an absolute (and incorrect) path for the binary
./desktop-make-non-absolute-exec.patch
];
dotnet-sdk = dotnetCorePackages.sdk_8_0;