tesseract: Build failed for ARM64 Windows10
-
Version :Tesseract-5.0.0-alpha-20201224:
-
Build For Windows ARM64 dll:
-
Build Tesseract:
cmake .. -G "Visual Studio 16 2019" -A ARM64 -DAUTO_OPTIMIZE=OFF -DSW_BUILD=OFF -DBUILD_TRAINING_TOOLS=OFF -DLeptonica_DIR=D:/OCR/Tesseract2/leptonica-1.81.1/arm64 -DCMAKE_INSTALL_PREFIX=../../build/x64
cmake --build . --config Release --target install
- I use the visual studio to compile it again and it failed :
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Comments: 16 (9 by maintainers)
Hi gents,
is it only me that sees tha lines in compile log: Vector unit list: sse2;sse3;ssse3;sse4.1;sse4.2;avx;fma;bmi2;avx2 HAVE_AVX: ON HAVE_AVX2: ON HAVE_FMA: ON HAVE_SSE4_1: ON scream that stonerey is probably doing it in command line that is not running on ARM64 processor and also does not have as compilatuion target arm64 ? Those settings I have highlited are all about possible optimizations for X64 processors that are not applicable at all for ARM64.
I did something very different for Windows on Arm but with sucess: I have Visual Studio, opened command line with settings to have tooling cfor AMD64 and target AMR64. Then I did:
git clone https://github.com/microsoft/vcpkg vcpkg\bootstrap-vcpkg.bat vcpkg\vcpkg install tesseract:arm64-windows-static
and after some 40-50 minutes (on Surface X) I got static version of tesseract 4.1 (current official release). Interestingly, bversion without static fails on one of the libraries needed. I will gladly share the resuting ARM64 code for tesseract.exe, it works nicely if decorated with necessary language and configuration files.
I will try to compile tesseract 5.x.x beta along the lines of stonerey effort, but with same command line on ARM64 based WOA machine.