Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ lib 2, buildPythonPackage 3, fetchPypi 4, fetchpatch 5, isPy3k 6, glibcLocales 7}: 8 9buildPythonPackage rec { 10 pname = "urwid"; 11 version = "2.1.2"; 12 format = "setuptools"; 13 14 src = fetchPypi { 15 inherit pname version; 16 sha256 = "588bee9c1cb208d0906a9f73c613d2bd32c3ed3702012f51efe318a3f2127eae"; 17 }; 18 19 patches = [ 20 # https://github.com/urwid/urwid/pull/517 21 (fetchpatch { 22 name = "python311-compat.patch"; 23 url = "https://github.com/urwid/urwid/commit/42c1ed1eeb663179b265bae9b384d7ec11c8a9b5.patch"; 24 hash = "sha256-Oz8O/M6AdqbB6C/BB5rtxp8FgdGhZUxkSxKIyq5Dmho="; 25 }) 26 ]; 27 28 # tests need to be able to set locale 29 LC_ALL = "en_US.UTF-8"; 30 nativeCheckInputs = [ glibcLocales ]; 31 32 # tests which assert on strings don't decode results correctly 33 doCheck = isPy3k; 34 35 pythonImportsCheck = [ 36 "urwid" 37 ]; 38 39 meta = with lib; { 40 description = "A full-featured console (xterm et al.) user interface library"; 41 homepage = "https://urwid.org/"; 42 license = licenses.lgpl21Plus; 43 maintainers = with maintainers; [ SuperSandro2000 ]; 44 }; 45}