1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-11-24 14:41:17 +00:00
nixpkgs/pkgs/games/commandergenius/default.nix

45 lines
1.3 KiB
Nix
Raw Normal View History

2016-07-13 18:24:18 +01:00
{ lib, stdenv, fetchFromGitHub, SDL2, SDL2_image, pkgconfig
, libvorbis, libGL, boost, cmake, zlib, curl, SDL2_mixer, python3
}:
2016-07-13 18:24:18 +01:00
stdenv.mkDerivation rec {
name = "commandergenius-${version}";
version = "2.2.0";
2016-07-13 18:24:18 +01:00
src = fetchFromGitHub {
owner = "gerstrong";
repo = "Commander-Genius";
rev = "v${version}";
sha256 = "1hjx4j325vj1ayxi3j2dpplpd3x0iqx98gyb093ld7dfnsyilbph";
2016-07-13 18:24:18 +01:00
};
buildInputs = [ SDL2 SDL2_image SDL2_mixer libGL boost libvorbis zlib curl python3 ];
preConfigure = ''
export cmakeFlags="$cmakeFlags -DCMAKE_INSTALL_PREFIX=$out -DSHAREDIR=$out/share"
export makeFlags="$makeFlags DESTDIR=$(out)"
'';
2016-07-13 18:24:18 +01:00
nativeBuildInputs = [ cmake pkgconfig ];
2016-07-13 18:24:18 +01:00
postPatch = ''
NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE $(sdl2-config --cflags)"
sed -i 's,APPDIR games,APPDIR bin,' src/install.cmake
2016-07-13 18:24:18 +01:00
'';
meta = with stdenv.lib; {
2016-07-13 18:24:18 +01:00
description = "Modern Interpreter for the Commander Keen Games";
longDescription = ''
2016-07-13 18:24:18 +01:00
Commander Genius is an open-source clone of
Commander Keen which allows you to play
the games, and some of the mods
made for it. All of the original data files
are required to do so
'';
homepage = https://github.com/gerstrong/Commander-Genius;
maintainers = with maintainers; [ hce ];
license = licenses.gpl2;
platforms = platforms.linux;
2016-07-13 18:24:18 +01:00
};
}