blob: 8e36ceffa59c8d05c4dd207221368164e4c365f7 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
|
{
lib,
buildPythonPackage,
fetchFromGitHub,
charls,
cython,
numpy,
pillow,
setuptools,
pytestCheckHook,
}:
buildPythonPackage rec {
pname = "pyjpegls";
version = "1.5.1";
pyproject = true;
src = fetchFromGitHub {
owner = "pydicom";
repo = "pyjpegls";
tag = "v${version}";
hash = "sha256-ha/nYvfzgoZDpVolMKMG9ZXqojy6x/2oPcvbWDvdKk4=";
};
# replace vendored 'charls' submodule with Nixpkgs's:
postPatch = ''
rmdir lib/charls
cp -ar ${charls.src} lib/charls
'';
pythonRelaxDeps = [ "numpy" ];
build-system = [
cython
numpy
setuptools
];
dependencies = [
numpy
pillow
];
pythonImportsCheck = [ "jpeg_ls" ];
nativeCheckInputs = [ pytestCheckHook ];
meta = {
description = "JPEG-LS for Python via CharLS C++ Library";
homepage = "https://github.com/pydicom/pyjpegls";
changelog = "https://github.com/pydicom/pyjpegls/releases/tag/v${src.tag}";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ bcdarwin ];
};
}
|