1{ lib , buildPythonPackage , fetchFromGitHub , pillow , zbar , pytestCheckHook }:
2
3buildPythonPackage rec {
4 pname = "python-zbar";
5 version = "0.23.90";
6 format = "setuptools";
7
8 src = fetchFromGitHub {
9 owner = "mchehab";
10 repo = "zbar";
11 rev = version;
12 sha256 = "sha256-FvV7TMc4JbOiRjWLka0IhtpGGqGm5fis7h870OmJw2U=";
13 };
14
15 propagatedBuildInputs = [ pillow ];
16
17 buildInputs = [ zbar ];
18
19 checkInputs = [ pytestCheckHook ];
20
21 preBuild = ''
22 cd python
23 '';
24
25 disabledTests = [
26 #AssertionError: b'Y800' != 'Y800'
27 "test_format"
28 "test_new"
29 #Requires loading a recording device
30 #zbar.SystemError: <zbar.Processor object at 0x7ffff615a680>
31 "test_processing"
32 ];
33
34 pythonImportsCheck = [ "zbar" ];
35
36 meta = with lib; {
37 description = "Python bindings for zbar";
38 homepage = "https://github.com/mchehab/zbar";
39 license = licenses.lgpl21Only;
40 maintainers = with maintainers; [ wolfangaukang ];
41 };
42}