nixpkgs/pkgs/games/gzdoom/default.nix
R. RyanTM f6c0588c97 gzdoom: 3.3.2 -> 3.4.0 (#42011)
Semi-automatic update generated by https://github.com/ryantm/nixpkgs-update tools.

This update was made based on information from https://repology.org/metapackage/gzdoom/versions.

These checks were done:

- built on NixOS
- Warning: no invocation of /nix/store/f4bpkw3bk3p8ca0vcxdi17hc5lm2r3jz-gzdoom-3.4.0/bin/gzdoom had a zero exit code or showed the expected version
- 0 of 1 passed binary check by having a zero exit code.
- 0 of 1 passed binary check by having the new version present in output.
- found 3.4.0 with grep in /nix/store/f4bpkw3bk3p8ca0vcxdi17hc5lm2r3jz-gzdoom-3.4.0
- directory tree listing: https://gist.github.com/1d92d331e8c24929e998260ca9018ddb
- du listing: https://gist.github.com/ba47c37ae7b73d3fb85a14b537b6c270
2018-06-18 22:53:32 +02:00

50 lines
1.4 KiB
Nix

{ stdenv, fetchFromGitHub, cmake, zdoom, makeWrapper
, openal, fluidsynth, soundfont-fluid, libGL, SDL2
, bzip2, zlib, libjpeg, libsndfile, mpg123, game-music-emu }:
stdenv.mkDerivation rec {
name = "gzdoom-${version}";
version = "3.4.0";
src = fetchFromGitHub {
owner = "coelckers";
repo = "gzdoom";
rev = "g${version}";
sha256 = "09400w0xpw6sk593c0fr6m9qmgn6n5r1qdardizim6m0r5ki565i";
};
nativeBuildInputs = [ cmake makeWrapper ];
buildInputs = [
SDL2 libGL openal fluidsynth bzip2 zlib libjpeg libsndfile mpg123
game-music-emu
];
enableParallelBuilding = true;
NIX_CFLAGS_LINK = [ "-lopenal" "-lfluidsynth" ];
preConfigure = ''
sed -i \
-e "s@/usr/share/sounds/sf2/@${soundfont-fluid}/share/soundfonts/@g" \
-e "s@FluidR3_GM.sf2@FluidR3_GM2-2.sf2@g" \
src/sound/mididevices/music_fluidsynth_mididevice.cpp
'';
installPhase = ''
install -Dm755 gzdoom "$out/lib/gzdoom/gzdoom"
for i in *.pk3; do
install -Dm644 "$i" "$out/lib/gzdoom/$i"
done
mkdir $out/bin
makeWrapper $out/lib/gzdoom/gzdoom $out/bin/gzdoom
'';
meta = with stdenv.lib; {
homepage = https://github.com/coelckers/gzdoom;
description = "A Doom source port based on ZDoom. It features an OpenGL renderer and lots of new features";
license = licenses.gpl3;
platforms = platforms.linux;
maintainers = with maintainers; [ lassulus ];
};
}