diff --git a/pkgs/development/python-modules/img2pdf/default.nix b/pkgs/development/python-modules/img2pdf/default.nix index f65c4b334a40..ed95dce85e58 100644 --- a/pkgs/development/python-modules/img2pdf/default.nix +++ b/pkgs/development/python-modules/img2pdf/default.nix @@ -1,7 +1,6 @@ { lib, buildPythonPackage, - isPy27, fetchFromGitea, replaceVars, fetchpatch, @@ -24,17 +23,15 @@ buildPythonPackage rec { pname = "img2pdf"; - version = "0.5.1"; - disabled = isPy27; - + version = "0.6.0"; pyproject = true; src = fetchFromGitea { domain = "gitlab.mister-muffin.de"; owner = "josch"; repo = "img2pdf"; - rev = version; - hash = "sha256-mrNTc37GrHTc7NW0sYI1FlAOlnvXum02867enqHsAEQ="; + tag = version; + hash = "sha256-/nxXgGsnj5ktxUYt9X8/9tJzXgoU8idTjVgLh+8jol8="; }; patches = [ @@ -48,16 +45,11 @@ buildPythonPackage rec { cp ${colord}/share/color/icc/colord/sRGB.icc $out ''; }) - (fetchpatch { - # https://gitlab.mister-muffin.de/josch/img2pdf/issues/178 - url = "https://salsa.debian.org/debian/img2pdf/-/raw/4a7dbda0f473f7c5ffcaaf68ea4ad3f435e0920d/debian/patches/fix_tests.patch"; - hash = "sha256-A1zK6yINhS+dvyckZjqoSO1XJRTaf4OXFdq5ufUrBs8="; - }) ]; - nativeBuildInputs = [ setuptools ]; + build-system = [ setuptools ]; - propagatedBuildInputs = [ + dependencies = [ pikepdf pillow ]; @@ -86,40 +78,20 @@ buildPythonPackage rec { disabledTests = [ # https://gitlab.mister-muffin.de/josch/img2pdf/issues/178 - "test_miff_cmyk16" - # https://gitlab.mister-muffin.de/josch/img2pdf/issues/205 + "test_jpg_cmyk" "test_miff_cmyk8" - "test_miff_rgb8" - "test_tiff_ccitt_lsb_m2l_white" - "test_tiff_ccitt_msb_l2m_white" - "test_tiff_ccitt_msb_m2l_white" - "test_tiff_ccitt_nometa1" - "test_tiff_ccitt_nometa2" "test_tiff_cmyk8" - "test_tiff_cmyk16" - "test_tiff_float" - "test_tiff_gray1" - "test_tiff_gray2" - "test_tiff_gray4" - "test_tiff_gray8" - "test_tiff_gray16" - "test_tiff_multipage" - "test_tiff_palette8" - "test_tiff_rgb8" - "test_tiff_rgb12" - "test_tiff_rgb14" - "test_tiff_rgb16" ]; pythonImportsCheck = [ "img2pdf" ]; - meta = with lib; { - changelog = "https://gitlab.mister-muffin.de/josch/img2pdf/src/tag/${src.rev}/CHANGES.rst"; + meta = { + changelog = "https://gitlab.mister-muffin.de/josch/img2pdf/src/tag/${src.tag}/CHANGES.rst"; description = "Convert images to PDF via direct JPEG inclusion"; homepage = "https://gitlab.mister-muffin.de/josch/img2pdf"; - license = licenses.lgpl3Plus; + license = lib.licenses.lgpl3Plus; mainProgram = "img2pdf"; - maintainers = with maintainers; [ + maintainers = with lib.maintainers; [ veprbl dotlambda ]; diff --git a/pkgs/development/python-modules/ocrmypdf/default.nix b/pkgs/development/python-modules/ocrmypdf/default.nix index dc87c6f4edfe..8ad3f94c534e 100644 --- a/pkgs/development/python-modules/ocrmypdf/default.nix +++ b/pkgs/development/python-modules/ocrmypdf/default.nix @@ -18,7 +18,6 @@ pngquant, pytest-xdist, pytestCheckHook, - pythonOlder, rich, reportlab, replaceVars, @@ -29,10 +28,7 @@ buildPythonPackage rec { pname = "ocrmypdf"; - version = "16.7.0"; - - disabled = pythonOlder "3.10"; - + version = "16.10.0"; pyproject = true; src = fetchFromGitHub { @@ -45,7 +41,7 @@ buildPythonPackage rec { postFetch = '' rm "$out/.git_archival.txt" ''; - hash = "sha256-81maXJjdGlzWy3TaQ8cabjJl6ZE5tbfc8m/+Px7ONhs="; + hash = "sha256-tRq3qskZK39xfSof4RUTWC2h9mi7eGDHR6nI7reltm4="; }; patches = [