nixpkgs/pkgs/development/python-modules/python-zbar/default.nix
Ihar Hrachyshka 567e8dfd8e
treewide: clean up 'meta = with' pattern
This commit was created by a combination of scripts and tools:
- an ast-grep script to prefix things in meta with `lib.`,
- a modified nixf-diagnose / nixf combination to remove unused `with
lib;`, and
- regular nixfmt.

Co-authored-by: Wolfgang Walther <walther@technowledgy.de>
2025-12-10 18:09:49 +01:00

55 lines
1 KiB
Nix

{
lib,
buildPythonPackage,
fetchFromGitHub,
setuptools,
pillow,
zbar,
pytestCheckHook,
}:
buildPythonPackage rec {
pname = "python-zbar";
version = "0.23.93";
pyproject = true;
src = fetchFromGitHub {
owner = "mchehab";
repo = "zbar";
tag = version;
hash = "sha256-6gOqMsmlYy6TK+iYPIBsCPAk8tYDliZYMYeTOidl4XQ=";
};
postPatch = ''
cd python
'';
build-system = [ setuptools ];
dependencies = [ pillow ];
buildInputs = [ zbar ];
nativeCheckInputs = [ pytestCheckHook ];
disabledTests = [
#AssertionError: b'Y800' != 'Y800'
"test_format"
"test_new"
#Requires loading a recording device
#zbar.SystemError: <zbar.Processor object at 0x7ffff615a680>
"test_processing"
# Version too long?
# self.assertEqual(len(ver), 2)
"test_version"
];
pythonImportsCheck = [ "zbar" ];
meta = {
description = "Python bindings for zbar";
homepage = "https://github.com/mchehab/zbar";
license = lib.licenses.lgpl21Only;
maintainers = [ ];
};
}