enable lazy linking for libandroid so that it can launch with missing symbols

Outdated Nvidia driver version 340 doesn't implement EGL and causes
following error:
symbol lookup error: /app/lib/libandroid.so.0: undefined symbol: eglGetPlatformDisplay

The crash can be avoided by lazy linking as long as the application doesn't
use EGL directly.
This commit is contained in:
Julian Winkler
2024-10-29 18:34:09 +01:00
committed by Mis012
parent 0efbee538a
commit 9b6c8db5ed

View File

@@ -73,6 +73,9 @@ libandroid_so = shared_library('android', [
], ],
c_args: [ c_args: [
'-D_LARGEFILE64_SOURCE', '-D_LARGEFILE64_SOURCE',
],
link_args : [
'-Wl,-z,lazy', # outdated Nvidia driver version 340 lacks EGL symbols
]) ])
libtranslationlayer_so = shared_library('translation_layer_main', [ libtranslationlayer_so = shared_library('translation_layer_main', [