Skip to content

Commit

Permalink
Merge pull request tesseract-ocr#3682 from leleliu008/improve-build-f…
Browse files Browse the repository at this point in the history
…or-android-integrate-with-cpu_features-library

fix for that motioned in tesseract-ocr#3680
  • Loading branch information
zdenop authored Jun 23, 2022
2 parents 18fb5aa + a96b2ab commit dd51e32
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -842,6 +842,13 @@ if(WIN32
target_link_libraries(libtesseract PRIVATE ${OpenMP_LIBRARY})
endif()

if (ANDROID)
add_definitions(-DANDROID)
find_package(CpuFeaturesNdkCompat REQUIRED)
target_include_directories(libtesseract PRIVATE "${CpuFeaturesNdkCompat_DIR}/../../../include/ndk_compat")
target_link_libraries (libtesseract PRIVATE CpuFeatures::ndk_compat)
endif()

# ##############################################################################
# EXECUTABLE tesseract
# ##############################################################################
Expand Down

0 comments on commit dd51e32

Please sign in to comment.