Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at 20.09 847 B view raw
1{ stdenv, lib, buildPythonPackage, fetchPypi, substituteAll 2, portmidi, pygame, python-rtmidi, rtmidi-python 3, pytest 4}: 5 6buildPythonPackage rec { 7 pname = "mido"; 8 version = "1.2.9"; 9 10 src = fetchPypi { 11 inherit pname version; 12 sha256 = "1k3sgkxc7j49bapib3b5jnircb1yhyyd8mi0mbfd78zgix9db9y4"; 13 }; 14 15 patches = [ 16 (substituteAll { 17 src = ./libportmidi-cdll.patch; 18 libportmidi = "${portmidi.out}/lib/libportmidi${stdenv.targetPlatform.extensions.sharedLibrary}"; 19 }) 20 ]; 21 22 propagatedBuildInputs = [ 23 pygame 24 python-rtmidi 25 rtmidi-python 26 ]; 27 28 checkInputs = [ pytest ]; 29 checkPhase = '' 30 py.test . -rs -q 31 ''; 32 33 meta = with lib; { 34 description = "MIDI Objects for Python"; 35 homepage = "https://mido.readthedocs.io"; 36 license = licenses.mit; 37 maintainers = with maintainers; [ hexa ]; 38 }; 39}