diff --git a/pkgs/applications/graphics/tesseract/tesseract5.nix b/pkgs/applications/graphics/tesseract/tesseract5.nix index a8563a09e4c0..22059873e4bb 100644 --- a/pkgs/applications/graphics/tesseract/tesseract5.nix +++ b/pkgs/applications/graphics/tesseract/tesseract5.nix @@ -1,17 +1,31 @@ -{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkg-config -, curl, leptonica, libarchive, libpng, libtiff, icu, pango, opencl-headers -, Accelerate, CoreGraphics, CoreVideo +{ + lib, + stdenv, + fetchFromGitHub, + nix-update-script, + autoreconfHook, + pkg-config, + curl, + leptonica, + libarchive, + libpng, + libtiff, + icu, + pango, + Accelerate, + CoreGraphics, + CoreVideo, }: stdenv.mkDerivation rec { pname = "tesseract"; - version = "5.3.4"; + version = "5.5.0"; src = fetchFromGitHub { owner = "tesseract-ocr"; repo = "tesseract"; rev = version; - sha256 = "sha256-IKxzDhSM+BPsKyQP3mADAkpRSGHs4OmdFIA+Txt084M="; + sha256 = "sha256-qyckAQZs3gR1NBqWgE+COSKXhv3kPF+iHVQrt6OPi8s="; }; enableParallelBuilding = true; @@ -21,26 +35,28 @@ stdenv.mkDerivation rec { autoreconfHook ]; - buildInputs = [ - curl - leptonica - libarchive - libpng - libtiff - icu - pango - opencl-headers - ] ++ lib.optionals stdenv.hostPlatform.isDarwin [ - Accelerate - CoreGraphics - CoreVideo - ]; + buildInputs = + [ + curl + leptonica + libarchive + libpng + libtiff + icu + pango + ] + ++ lib.optionals stdenv.hostPlatform.isDarwin [ + Accelerate + CoreGraphics + CoreVideo + ]; + passthru.updateScript = nix-update-script { }; meta = { description = "OCR engine"; homepage = "https://github.com/tesseract-ocr/tesseract"; license = lib.licenses.asl20; - maintainers = [ ]; + maintainers = with lib.maintainers; [ patrickdag ]; platforms = lib.platforms.unix; mainProgram = "tesseract"; }; diff --git a/pkgs/development/python-modules/pytesseract/default.nix b/pkgs/development/python-modules/pytesseract/default.nix index 23a26fd52a1b..a12730c9f584 100644 --- a/pkgs/development/python-modules/pytesseract/default.nix +++ b/pkgs/development/python-modules/pytesseract/default.nix @@ -37,6 +37,11 @@ buildPythonPackage rec { packaging pillow ]; + disabledTests = [ + # https://github.com/madmaze/pytesseract/pull/559 + "incorrect_tessdata_dir" + "invalid_tessdata_dir" + ]; nativeCheckInputs = [ pytestCheckHook ];