depot/third_party/nixpkgs/pkgs/development/python-modules/mido/default.nix
Default email 1ffc76754d Project import generated by Copybara.
GitOrigin-RevId: a5cc7d3197705f933d88e97c0c61849219ce76c1
2020-07-18 18:06:22 +02:00

39 lines
847 B
Nix

{ stdenv, lib, buildPythonPackage, fetchPypi, substituteAll
, portmidi, pygame, python-rtmidi, rtmidi-python
, pytest
}:
buildPythonPackage rec {
pname = "mido";
version = "1.2.9";
src = fetchPypi {
inherit pname version;
sha256 = "1k3sgkxc7j49bapib3b5jnircb1yhyyd8mi0mbfd78zgix9db9y4";
};
patches = [
(substituteAll {
src = ./libportmidi-cdll.patch;
libportmidi = "${portmidi.out}/lib/libportmidi${stdenv.targetPlatform.extensions.sharedLibrary}";
})
];
propagatedBuildInputs = [
pygame
python-rtmidi
rtmidi-python
];
checkInputs = [ pytest ];
checkPhase = ''
py.test . -rs -q
'';
meta = with lib; {
description = "MIDI Objects for Python";
homepage = "https://mido.readthedocs.io";
license = licenses.mit;
maintainers = with maintainers; [ hexa ];
};
}