Skip to content

Commit

Permalink
meritous: init at 1.4
Browse files Browse the repository at this point in the history
  • Loading branch information
alexvorobiev authored and fpletz committed Oct 24, 2017
1 parent c47d77c commit 770bedb
Show file tree
Hide file tree
Showing 3 changed files with 43 additions and 0 deletions.
1 change: 1 addition & 0 deletions lib/maintainers.nix
Expand Up @@ -31,6 +31,7 @@
ak = "Alexander Kjeldaas <ak@formalprivacy.com>";
akaWolf = "Artjom Vejsel <akawolf0@gmail.com>";
akc = "Anders Claesson <akc@akc.is>";
alexvorobiev = "Alex Vorobiev <alexander.vorobiev@gmail.com";
algorith = "Dries Van Daele <dries_van_daele@telenet.be>";
alibabzo = "Alistair Bill <alistair.bill@gmail.com>";
all = "Nix Committers <nix-commits@lists.science.uu.nl>";
Expand Down
40 changes: 40 additions & 0 deletions pkgs/games/meritous/default.nix
@@ -0,0 +1,40 @@
{ stdenv, fetchFromGitLab, SDL, SDL_image, SDL_mixer, zlib, binutils }:

stdenv.mkDerivation rec {
name = "meritous-${version}";
version = "1.4";

src = fetchFromGitLab {
owner = "meritous";
repo = "meritous";
rev = "314af46d84d2746eec4c30a0f63cbc2e651d5303";
sha256 = "1hrwm65isg5nwzydyd8gvgl3p36sbj09rsn228sppr8g5p9sm10x";
};

prePatch = ''
substituteInPlace Makefile \
--replace "CPPFLAGS +=" "CPPFLAGS += -DSAVES_IN_HOME -DDATADIR=\\\"$out/share/meritous\\\"" \
--replace sld-config ${SDL.dev}/bin/sdl-config
substituteInPlace src/audio.c \
--replace "filename[64]" "filename[256]"
'';

buildInputs = [ SDL SDL_image SDL_mixer zlib ];

installPhase = ''
install -m 555 -D meritous $out/bin/meritous
mkdir -p $out/share/meritous
cp -r dat/* $out/share/meritous/
'';

hardeningDisable = [ "stackprotector" "fortify" ];

meta = with stdenv.lib; {
description = "Action-adventure dungeon crawl game";
homepage = http://www.asceai.net/meritous/;
license = licenses.gpl3;
maintainers = [ maintainers.alexvorobiev ];
platforms = platforms.linux;
};
}

2 changes: 2 additions & 0 deletions pkgs/top-level/all-packages.nix
Expand Up @@ -1141,6 +1141,8 @@ with pkgs;

masscan = callPackage ../tools/security/masscan { };

meritous = callPackage ../games/meritous { };

meson = callPackage ../development/tools/build-managers/meson { };

mp3fs = callPackage ../tools/filesystems/mp3fs { };
Expand Down

0 comments on commit 770bedb

Please sign in to comment.