retrospy: fix icon resolution (#311127)
This commit is contained in:
parent
f46f95fb3e
commit
d60ffedd11
@ -9,21 +9,11 @@
|
||||
, libXcursor
|
||||
, libICE
|
||||
, libSM
|
||||
, runCommandLocal
|
||||
}:
|
||||
let
|
||||
version = "6.4.8";
|
||||
|
||||
executables = [
|
||||
"RetroSpy"
|
||||
"GBPemu"
|
||||
"GBPUpdater"
|
||||
"UsbUpdater"
|
||||
];
|
||||
in
|
||||
buildDotnetModule {
|
||||
pname = "retrospy";
|
||||
inherit version;
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "retrospy";
|
||||
repo = "RetroSpy";
|
||||
@ -31,6 +21,24 @@ buildDotnetModule {
|
||||
hash = "sha256-0rdLdud78gnBX8CIdG81caJ1IRoIjGzb7coP4huEPDA=";
|
||||
};
|
||||
|
||||
executables = [
|
||||
"RetroSpy"
|
||||
"GBPemu"
|
||||
"GBPUpdater"
|
||||
"UsbUpdater"
|
||||
];
|
||||
|
||||
retrospy-icons = runCommandLocal "retrospy-icons" { } ''
|
||||
mkdir -p $out/share/retrospy
|
||||
${builtins.concatStringsSep "\n" (map (e: "cp ${src}/${e}.ico $out/share/retrospy/${e}.ico") executables)}
|
||||
'';
|
||||
in
|
||||
buildDotnetModule {
|
||||
pname = "retrospy";
|
||||
inherit version;
|
||||
|
||||
inherit src;
|
||||
|
||||
nativeBuildInputs = [
|
||||
copyDesktopItems
|
||||
];
|
||||
@ -57,18 +65,13 @@ buildDotnetModule {
|
||||
|
||||
inherit executables;
|
||||
|
||||
postInstall = ''
|
||||
mkdir -p $out/share/retrospy
|
||||
${builtins.concatStringsSep "\n" (map (e: "cp ./${e}.ico $out/share/retrospy/${e}.ico") executables)}
|
||||
'';
|
||||
|
||||
passthru.updateScript = ./update.sh;
|
||||
|
||||
desktopItems = map
|
||||
(e: (makeDesktopItem {
|
||||
name = e;
|
||||
exec = e;
|
||||
icon = "${placeholder "out"}/share/retrospy/${e}.ico";
|
||||
icon = "${retrospy-icons}/share/retrospy/${e}.ico";
|
||||
desktopName = "${e}";
|
||||
categories = [ "Utility" ];
|
||||
startupWMClass = e;
|
||||
|
Loading…
Reference in New Issue
Block a user