diff --git a/pkgs/by-name/gd/gdevelop/package.nix b/pkgs/by-name/gd/gdevelop/package.nix index c1279c0eb02b..8109ecb2a89f 100644 --- a/pkgs/by-name/gd/gdevelop/package.nix +++ b/pkgs/by-name/gd/gdevelop/package.nix @@ -16,15 +16,24 @@ let } else throw "${pname}-${version} is not supported on ${stdenv.hostPlatform.system}"; - - appimageContents = appimageTools.extractType2 { inherit pname src; }; - + appimageContents = appimageTools.extractType2 { + inherit pname version src; + postExtract = '' + substituteInPlace $out/gdevelop.desktop --replace-fail 'Exec=AppRun --no-sandbox %U' 'Exec=gdevelop' + ''; + }; dontPatchELF = true; - in appimageTools.wrapType2 { inherit pname version src; + extraInstallCommands = '' + mkdir -p $out/share/applications + cp ${appimageContents}/gdevelop.desktop $out/share/applications + mkdir -p $out/share/icons + cp -r ${appimageContents}/usr/share/icons/hicolor $out/share/icons + ''; + meta = { description = "Graphical Game Development Studio"; homepage = "https://gdevelop.io/"; @@ -32,7 +41,7 @@ appimageTools.wrapType2 { license = lib.licenses.mit; sourceProvenance = with lib.sourceTypes; [ binaryNativeCode ]; maintainers = with lib.maintainers; [ tombert ]; + mainProgram = "gdevelop"; platforms = [ "x86_64-linux" ]; }; - }