Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tesseract 5.4.0 #173888

Merged
merged 2 commits into from
Jun 7, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 15 additions & 16 deletions Formula/t/tesseract.rb
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
class Tesseract < Formula
desc "OCR (Optical Character Recognition) engine"
homepage "https://github.com/tesseract-ocr/"
url "https://github.com/tesseract-ocr/tesseract/archive/refs/tags/5.3.4.tar.gz"
sha256 "141afc12b34a14bb691a939b4b122db0d51bd38feda7f41696822bacea7710c7"
url "https://github.com/tesseract-ocr/tesseract/archive/refs/tags/5.4.0.tar.gz"
sha256 "30ceffd9b86780f01cbf4eaf9b7fc59abddfcbaf5bbd52f9a633c6528cb183fd"
license "Apache-2.0"
revision 1
head "https://github.com/tesseract-ocr/tesseract.git", branch: "main"

livecheck do
Expand All @@ -13,13 +12,13 @@ class Tesseract < Formula
end

bottle do
sha256 cellar: :any, arm64_sonoma: "6025ab29df5d7c96b4402964c393f02a3c8b12a1cced36d985ad26a0739c18d9"
sha256 cellar: :any, arm64_ventura: "f3781bcc17a408b0b595864460fbfb72f5c8792766c324fcfadf4300693eaade"
sha256 cellar: :any, arm64_monterey: "293eb4c6ae34966a4cbd869fa1ee4e8542d9c11e4daaf7249b1f13c82890d5b6"
sha256 cellar: :any, sonoma: "767999fd87af693c0505bd06e26507c15b063d03a852c68da74974fccf7c15b8"
sha256 cellar: :any, ventura: "80ce438228ee16bc9693b9b5d7eb1eb67b3385e9f6b256941539737ce9a75670"
sha256 cellar: :any, monterey: "11977a77350497b9b260966fa0b2f746e2f3e27646fe2896d87c97a1f84f2c9f"
sha256 cellar: :any_skip_relocation, x86_64_linux: "5cac1de32545da7765422c9b9bcef0bb9e8b4eb9f719ec52fe01fc68807a77af"
sha256 cellar: :any, arm64_sonoma: "c18159a800c3db208ca4ac48a41223795d50d96bb338101aebd28b0a14fdfa49"
sha256 cellar: :any, arm64_ventura: "b0f2f6b3f81031438b184354081828fa329d31abc5e015cd75be77cbf0619115"
sha256 cellar: :any, arm64_monterey: "655fe566eaa87ca167e6a62563ca4148d7a1a2f6a251f21d7bdf2376dbc46c80"
sha256 cellar: :any, sonoma: "1506318adafb39d45305a775ba5cac53f6462df067d2aa85f863d50606d09489"
sha256 cellar: :any, ventura: "78beb92bc43cb96bcda3f00d8cca13a8aefcbf39666ed30ca535649135ea0d79"
sha256 cellar: :any, monterey: "4a1e198c7acc79855888d9c7b350a50d3085a31601d4843f5c766835a7e93457"
sha256 cellar: :any_skip_relocation, x86_64_linux: "11ec01279baef11b5a1b8df493db3c44c955becce2da34986901d3538f1f3b2a"
end

depends_on "autoconf" => :build
Expand Down Expand Up @@ -49,11 +48,6 @@ class Tesseract < Formula
sha256 "36f772980ff17c66a767f584a0d80bf2302a1afa585c01a226c1863afcea1392"
end

resource "test_resource" do
url "https://raw.githubusercontent.com/tesseract-ocr/test/6dd816cdaf3e76153271daf773e562e24c928bf5/testing/eurotext.tif"
sha256 "7b9bd14aba7d5e30df686fbb6f71782a97f48f81b32dc201a1b75afe6de747d6"
end

def install
# explicitly state leptonica header location, as the makefile defaults to /usr/local/include,
# which doesn't work for non-default homebrew location
Expand Down Expand Up @@ -84,7 +78,12 @@ def caveats
end

test do
resource("test_resource").stage do
resource "homebrew-test_resource" do
url "https://raw.githubusercontent.com/tesseract-ocr/test/6dd816cdaf3e76153271daf773e562e24c928bf5/testing/eurotext.tif"
sha256 "7b9bd14aba7d5e30df686fbb6f71782a97f48f81b32dc201a1b75afe6de747d6"
end

resource("homebrew-test_resource").stage do
system bin/"tesseract", "./eurotext.tif", "./output", "-l", "eng"
assert_match "The (quick) [brown] {fox} jumps!\n", File.read("output.txt")
end
Expand Down
Loading