File tree Expand file tree Collapse file tree 4 files changed +6
-44
lines changed Expand file tree Collapse file tree 4 files changed +6
-44
lines changed Original file line number Diff line number Diff line change 11PKG_CPPFLAGS=@cflags@
22
3- # Force shared library linking by explicitly changing .a to .so
4- PKG_LIBS=$(subst .a,.so, @libs@)
3+ # Link against Tesseract and Leptonica libraries
4+ PKG_LIBS=@libs@
55
66# Set C++11 standard for compatibility
77CXX_STD=CXX11
Original file line number Diff line number Diff line change @@ -124,8 +124,8 @@ tesseract::TessBaseAPI *get_engine(TessPtr engine) {
124124 writable::logicals out (params.size ());
125125 STRING str;
126126 for (int i = 0 ; i < params.size (); i++) {
127- #if defined(TESSERACT_HAS_GETVARIABLEASSTRING)
128- // Use the newer API
127+ #if defined(TESSERACT_HAS_GETVARIABLEASSTRING) && !defined(__clang__)
128+ // Use the newer API - but avoid with clang due to linking issues
129129 out[i] = api->GetVariableAsString (std::string (params.at (i)).c_str (), &str);
130130#else
131131 const char *value =
@@ -176,8 +176,8 @@ tesseract::TessBaseAPI *get_engine(TessPtr engine) {
176176 std::vector<std::string> values;
177177 for (int i = 0 ; i < params.size (); ++i) {
178178 STRING str;
179- #if defined(TESSERACT_HAS_GETVARIABLEASSTRING)
180- // Use the newer API
179+ #if defined(TESSERACT_HAS_GETVARIABLEASSTRING) && !defined(__clang__)
180+ // Use the newer API - but avoid with clang due to linking issues
181181 if (api->GetVariableAsString (std::string (params.at (i)).c_str (), &str)) {
182182 values.push_back (str);
183183#else
Original file line number Diff line number Diff line change 1- // Windows-specific symbol fixes
2- #include " win_symbol_fixes.h"
3-
41// Try multiple include paths for better cross-platform compatibility
52#if __APPLE__
63// On macOS, try multiple include paths
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments