depot/third_party/nixpkgs/pkgs/development/python-modules/manimpango/default.nix
Default email 792b51d22f Project import generated by Copybara.
GitOrigin-RevId: d5f237872975e6fb6f76eef1368b5634ffcd266f
2022-02-20 05:27:41 +00:00

37 lines
973 B
Nix

{ stdenv, lib, buildPythonPackage, fetchFromGitHub, python, pkg-config, pango, cython, AppKit, pytestCheckHook }:
buildPythonPackage rec {
pname = "manimpango";
version = "0.4.0.post2";
src = fetchFromGitHub {
owner = "ManimCommunity";
repo = pname;
rev = "v${version}";
sha256 = "sha256-BMRlEdvJJOUbsvKEoZx2qJqHSbL475dhBthUpnsXkn4=";
};
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.mit;
description = "Binding for Pango";
maintainers = [ maintainers.emilytrau ];
};
}