1 { stdenv, lib, rustPlatform, fetchFromGitHub, SDL2, makeWrapper, makeDesktopItem}:
4 desktopFile = makeDesktopItem {
5 name = "system-syzygy";
6 exec = "@out@/bin/syzygy";
7 comment = "A puzzle game";
8 desktopName = "System Syzygy";
9 categories = [ "Game" ];
12 rustPlatform.buildRustPackage rec {
13 pname = "system-syzygy";
16 src = fetchFromGitHub {
19 rev = "5ba148fed7aae14bf35108d7303e4194e8ffe5e8";
20 sha256 = "07mzwx8ql33q865snnw4gm3dgf0mnm60lnq1f5fgas2yjy9g9vwa";
23 nativeBuildInputs = [ makeWrapper ];
24 buildInputs = [ SDL2 ];
27 lockFile = ./Cargo.lock;
29 "ahi-0.1.0" = "sha256-EliAObznLP1wkk8r3c3hhB300HYnEd9N6CJW+xG6bxE=";
30 "itersynth-0.1.0" = "sha256-dXQ+uBFchcnOjKF/CcS+AwhzFzejk2JCvvKMfS64RRQ=";
31 "sdl2-0.31.0" = "sha256-wTam0hwiajdw/ub2yM6q7+50Y3AueStcK5HLa65Y2XQ=";
32 "winres-0.1.6" = "sha256-7jYrgc3BV2UmzfACc/xyYsTkaXBPfn+bLmwdrcBe1O0=";
37 mkdir -p $out/share/syzygy/
38 cp -r ${src}/data/* $out/share/syzygy/
39 wrapProgram $out/bin/syzygy --set SYZYGY_DATA_DIR $out/share/syzygy
40 mkdir -p $out/share/applications
41 substituteAll ${desktopFile}/share/applications/system-syzygy.desktop $out/share/applications/system-syzygy.desktop
46 broken = stdenv.hostPlatform.isDarwin;
47 description = "Story and a puzzle game, where you solve a variety of puzzle";
48 mainProgram = "syzygy";
49 homepage = "https://mdsteele.games/syzygy";
50 license = licenses.gpl3Plus;
51 maintainers = [ maintainers.marius851000 ];