nixpkgs/pkgs/development/python-modules/pyglet/default.nix
2018-02-18 20:07:43 +01:00

28 lines
787 B
Nix

{ stdenv, buildPythonPackage, fetchPypi
, mesa, xorg, freetype, fontconfig, future}:
buildPythonPackage rec {
version = "1.3.1";
pname = "pyglet";
src = fetchPypi {
inherit pname version;
sha256 = "0a73280fa3949ea4890fee28f625c10b1e10a7cda390a08b6bce4740948167cd";
};
postPatch = let
libs = [ mesa xorg.libX11 freetype fontconfig ];
paths = builtins.concatStringsSep "," (map (l: "\"${l}/lib\"") libs);
in "sed -i -e 's|directories\.extend.*lib[^]]*|&,${paths}|' pyglet/lib.py";
doCheck = false;
propagatedBuildInputs = [ future ];
meta = with stdenv.lib; {
homepage = "http://www.pyglet.org/";
description = "A cross-platform windowing and multimedia library";
license = licenses.bsd3;
platforms = platforms.mesaPlatforms;
};
}