Commit 7b59c8c9 for tesseract
commit 7b59c8c97a8952b2b1dc3ff7d13ddc13b268ed18
Author: Stefan Weil <sw@weilnetz.de>
Date: Thu Nov 26 17:04:03 2026 +0100
CI: don't download fonts from SourceForge for the unit tests
"make check" needs the fonts Arial_Bold_Italic.ttf, Times_New_Roman.ttf
and Verdana.ttf and downloads them from SourceForge if they are
missing. Such a download fails from time to time (HTTP status 504,
timeout), and then the whole job fails before a test has run.
The workflows already get the same three files from the repository
with the test data, but with other names (Arialbi.TTF, Times.TTF,
Verdana.TTF). Copy them to the names which "make check" expects in all
workflows which run it, so no download is needed.
Assisted-by: Claude Fable 5.2 (Anthropic)
Signed-off-by: Stefan Weil <sw@weilnetz.de>
diff --git a/.github/workflows/autotools-macos.yml b/.github/workflows/autotools-macos.yml
index 62f6187a..6d885405 100644
--- a/.github/workflows/autotools-macos.yml
+++ b/.github/workflows/autotools-macos.yml
@@ -25,6 +25,11 @@ jobs:
run: |
git clone https://github.com/egorpugin/tessdata tessdata_unittest
cp tessdata_unittest/fonts/* test/testing/
+ # Add the fonts with the names which "make check" expects. They are the
+ # same files which it would download from SourceForge otherwise.
+ cp tessdata_unittest/fonts/Arialbi.TTF test/testing/Arial_Bold_Italic.ttf
+ cp tessdata_unittest/fonts/Times.TTF test/testing/Times_New_Roman.ttf
+ cp tessdata_unittest/fonts/Verdana.TTF test/testing/Verdana.ttf
mv tessdata_unittest/* ../
- name: Install dependencies
@@ -127,6 +132,11 @@ jobs:
run: |
git clone https://github.com/egorpugin/tessdata tessdata_unittest
cp tessdata_unittest/fonts/* test/testing/
+ # Add the fonts with the names which "make check" expects. They are the
+ # same files which it would download from SourceForge otherwise.
+ cp tessdata_unittest/fonts/Arialbi.TTF test/testing/Arial_Bold_Italic.ttf
+ cp tessdata_unittest/fonts/Times.TTF test/testing/Times_New_Roman.ttf
+ cp tessdata_unittest/fonts/Verdana.TTF test/testing/Verdana.ttf
mv tessdata_unittest/* ../
- name: Install Macports
diff --git a/.github/workflows/autotools.yml b/.github/workflows/autotools.yml
index df50576b..95a68bc2 100644
--- a/.github/workflows/autotools.yml
+++ b/.github/workflows/autotools.yml
@@ -29,6 +29,11 @@ jobs:
run: |
git clone https://github.com/egorpugin/tessdata tessdata_unittest
cp tessdata_unittest/fonts/* test/testing/
+ # Add the fonts with the names which "make check" expects. They are the
+ # same files which it would download from SourceForge otherwise.
+ cp tessdata_unittest/fonts/Arialbi.TTF test/testing/Arial_Bold_Italic.ttf
+ cp tessdata_unittest/fonts/Times.TTF test/testing/Times_New_Roman.ttf
+ cp tessdata_unittest/fonts/Verdana.TTF test/testing/Verdana.ttf
mv tessdata_unittest/* ../
- name: Install Compiler
diff --git a/.github/workflows/unittest-disablelegacy.yml b/.github/workflows/unittest-disablelegacy.yml
index b5fa8927..b0bfda07 100644
--- a/.github/workflows/unittest-disablelegacy.yml
+++ b/.github/workflows/unittest-disablelegacy.yml
@@ -59,6 +59,11 @@ jobs:
run: |
git clone https://github.com/egorpugin/tessdata tessdata_unittest
cp tessdata_unittest/fonts/* test/testing/
+ # Add the fonts with the names which "make check" expects. They are the
+ # same files which it would download from SourceForge otherwise.
+ cp tessdata_unittest/fonts/Arialbi.TTF test/testing/Arial_Bold_Italic.ttf
+ cp tessdata_unittest/fonts/Times.TTF test/testing/Times_New_Roman.ttf
+ cp tessdata_unittest/fonts/Verdana.TTF test/testing/Verdana.ttf
mv tessdata_unittest/* ../
- name: Run Tesseract on phototest.tif and devatest.png
diff --git a/.github/workflows/unittest-macos.yml b/.github/workflows/unittest-macos.yml
index 1f04c8d4..90be8a6a 100644
--- a/.github/workflows/unittest-macos.yml
+++ b/.github/workflows/unittest-macos.yml
@@ -65,6 +65,11 @@ jobs:
run: |
git clone https://github.com/egorpugin/tessdata tessdata_unittest
cp tessdata_unittest/fonts/* test/testing/
+ # Add the fonts with the names which "make check" expects. They are the
+ # same files which it would download from SourceForge otherwise.
+ cp tessdata_unittest/fonts/Arialbi.TTF test/testing/Arial_Bold_Italic.ttf
+ cp tessdata_unittest/fonts/Times.TTF test/testing/Times_New_Roman.ttf
+ cp tessdata_unittest/fonts/Verdana.TTF test/testing/Verdana.ttf
mv tessdata_unittest/* ../
- name: Run Tesseract on phototest.tif and devatest.png
diff --git a/.github/workflows/unittest.yml b/.github/workflows/unittest.yml
index d7037e81..0c72cf75 100644
--- a/.github/workflows/unittest.yml
+++ b/.github/workflows/unittest.yml
@@ -79,6 +79,11 @@ jobs:
run: |
git clone https://github.com/egorpugin/tessdata tessdata_unittest
cp tessdata_unittest/fonts/* test/testing/
+ # Add the fonts with the names which "make check" expects. They are the
+ # same files which it would download from SourceForge otherwise.
+ cp tessdata_unittest/fonts/Arialbi.TTF test/testing/Arial_Bold_Italic.ttf
+ cp tessdata_unittest/fonts/Times.TTF test/testing/Times_New_Roman.ttf
+ cp tessdata_unittest/fonts/Verdana.TTF test/testing/Verdana.ttf
mv tessdata_unittest/* ../
- name: Run Tesseract on phototest.tif and devatest.png