1 { lib, stdenv, fetchFromGitLab, SDL, SDL_image, SDL_mixer, zlib }:
3 stdenv.mkDerivation (finalAttrs: {
7 src = fetchFromGitLab {
10 rev = "refs/tags/v${finalAttrs.version}";
11 hash = "sha256-6KK2anjX+fPsYf4HSOHQ0EQBINqZiVbxo1RmBR6pslg=";
15 substituteInPlace Makefile \
16 --replace "prefix=/usr/local" "prefix=$out" \
17 --replace sdl-config ${lib.getDev SDL}/bin/sdl-config
19 substituteInPlace src/audio.c \
20 --replace "filename[64]" "filename[256]"
23 buildInputs = [ SDL SDL_image SDL_mixer zlib ];
26 install -m 555 -D meritous $out/bin/meritous
27 mkdir -p $out/share/meritous
28 cp -r dat/* $out/share/meritous/
31 hardeningDisable = [ "stackprotector" "fortify" ];
34 description = "Action-adventure dungeon crawl game";
35 homepage = "https://gitlab.com/meritous/meritous";
36 changelog = "https://gitlab.com/meritous/meritous/-/blob/master/NEWS";
37 license = licenses.gpl3Only;
38 mainProgram = "meritous";
39 maintainers = [ maintainers.alexvorobiev ];
40 platforms = platforms.linux;