depot/third_party/nixpkgs/pkgs/development/python-modules/manimpango/default.nix
Default email ce641f4048 Project import generated by Copybara.
GitOrigin-RevId: bc5d68306b40b8522ffb69ba6cff91898c2fbbff
2021-12-06 17:07:01 +01:00

37 lines
965 B
Nix

{ stdenv, lib, buildPythonPackage, fetchFromGitHub, python, pkg-config, pango, cython, AppKit, pytestCheckHook }:
buildPythonPackage rec {
pname = "manimpango";
version = "0.3.1";
src = fetchFromGitHub {
owner = "ManimCommunity";
repo = pname;
rev = "v${version}";
sha256 = "ldZfvv5kloQ0uj0agxOP8cRh+Ix8f9Z0PT+pnhWYjiQ=";
};
postPatch = ''
substituteInPlace setup.cfg --replace "--cov --no-cov-on-fail" ""
'';
nativeBuildInputs = [ pkg-config ];
buildInputs = [ pango ] ++ lib.optionals stdenv.isDarwin [ AppKit ];
propagatedBuildInputs = [
cython
];
preBuild = ''
${python.interpreter} setup.py build_ext --inplace
'';
checkInputs = [ pytestCheckHook ];
pythonImportsCheck = [ "manimpango" ];
meta = with lib; {
homepage = "https://github.com/ManimCommunity/ManimPango";
license = licenses.gpl3Plus;
description = "Binding for Pango";
maintainers = [ maintainers.angustrau ];
};
}