14 # Doesn't seem to be included in tagged releases, but does exist on master.
16 url = "https://raw.githubusercontent.com/sergiou87/open-supaplex/b102548699cf16910b59559f689ecfad88d2a7d2/open-supaplex.svg";
17 sha256 = "sha256-nKeSBUGjSulbEP7xxc6smsfCRjyc/xsLykH0o3Rq5wo=";
20 stdenv.mkDerivation rec {
21 pname = "opensupaplex";
24 src = fetchFromGitHub {
26 repo = "open-supaplex";
28 sha256 = "sha256-hP8dJlLXE5J/oxPhRkrrBl1Y5e9MYbJKi8OApFM3+GU=";
32 SDL2 # For "sdl2-config"
35 buildInputs = [ SDL2_mixer ];
37 enableParallelBuilding = true;
39 env.NIX_CFLAGS_COMPILE = toString [
40 "-DFILE_DATA_PATH=${placeholder "out"}/lib/opensupaplex"
45 # Makefile is located in this directory
56 mkdir -p $out/{bin,lib,share/icons/hicolor/scalable/apps}
58 install -D ./linux/opensupaplex $out/bin/opensupaplex
59 cp -R ./resources $out/lib/opensupaplex
60 cp ${icon} $out/share/icons/hicolor/scalable/apps/open-supaplex.svg
65 passthru.tests.version = testers.testVersion {
66 package = opensupaplex;
67 command = "opensupaplex --help";
68 version = "v${version}";
71 desktopItems = [(makeDesktopItem {
72 name = "opensupaplex";
73 exec = meta.mainProgram;
74 icon = "open-supaplex";
75 desktopName = "OpenSupaplex";
76 comment = meta.description;
77 categories = [ "Application" "Game" ];
81 description = "A decompilation of Supaplex in C and SDL";
82 homepage = "https://github.com/sergiou87/open-supaplex";
83 changelog = "https://github.com/sergiou87/open-supaplex/blob/master/changelog/v${version}.txt";
84 license = licenses.gpl3Only;
85 maintainers = [ maintainers.ivar ];
86 platforms = platforms.linux; # Many more are supported upstream, but only linux is tested.
87 mainProgram = "opensupaplex";