From: Twaik Yont <9674930+twaik@users.noreply.github.com> The java_vm, java_object and java_gdt_sel globals are looked up via dlsym, but can end up with hidden visibility and therefore missing from the dynamic symbol table. Explicitly export these symbols to ensure they remain visible to dlsym. This appears to be required with newer Android NDK toolchains, likely related to changes in symbol visibility handling (for example Android NDK r22). Reference: https://github.com/android/ndk/wiki/Changelog-r22 Signed-off-by: Twaik Yont <9674930+twaik@users.noreply.github.com> --- dlls/ntdll/unix/loader.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/dlls/ntdll/unix/loader.c b/dlls/ntdll/unix/loader.c index c9696fef115..5b765d7a869 100644 --- a/dlls/ntdll/unix/loader.c +++ b/dlls/ntdll/unix/loader.c @@ -1809,9 +1809,9 @@ static void start_main_thread(void) #define WINE_JAVA_CLASS "org/winehq/wine/WineActivity" #endif -JavaVM *java_vm = NULL; -jobject java_object = 0; -unsigned short java_gdt_sel = 0; +DECLSPEC_EXPORT JavaVM *java_vm = NULL; +DECLSPEC_EXPORT jobject java_object = 0; +DECLSPEC_EXPORT unsigned short java_gdt_sel = 0; /* main Wine initialisation */ static jstring wine_init_jni( JNIEnv *env, jobject obj, jobjectArray cmdline, jobjectArray environment ) -- GitLab https://gitlab.winehq.org/wine/wine/-/merge_requests/9977