Compile Tesseract-OCR for Android ARM64 use x86_64-linux-gnu headers

Hello,

When I configure a Tesseract-OCR project for Android arm64-v8a on Ubuntu, I use the following settings :

set(CMAKE_TOOLCHAIN_FILE /home/user/SDKs/android_ndk/android_ndk_clang/build/cmake/android.toolchain.cmake)
set(ANDROID_ABI arm64-v8a)
set(ANDROID_PLATFORM 26) 
set(ANDROID_STL c++_shared)

I receive this message using make command:

/usr/include/x86_64-linux-gnu/sys/cdefs.h:64:6: error: function-like macro '__GNUC_PREREQ' is not defined
    64 | # if __GNUC_PREREQ (4, 6) && !defined _LIBC
       |      ^
/usr/include/x86_64-linux-gnu/sys/cdefs.h:78:10: error: function-like macro '__GNUC_PREREQ' is not defined
    78 |      && (__GNUC_PREREQ (3, 4) || __glibc_has_attribute
(__nothrow__))
       |          ^
/usr/include/x86_64-linux-gnu/sys/cdefs.h:84:31: error: function-like macro '__GNUC_PREREQ' is not defined
    84 | #  if defined __cplusplus && (__GNUC_PREREQ (2,8) || __clang_major__ >= 4)
       |

I don’t understand why Tesseract-OCR for Android ARM64 use x86_64-linux-gnu headers instead of Android NDK headers ?
How I can solve this behavior ?
Thanks

Are those values exchanged?

No, those two values are not swapped — they serve different purposes in an Android NDK CMake configuration.

Where are you setting this exactly?

in <project>/cross-compiling/android/arm64-v8a/android.toolchain.config.cmake