Skip to content

android: prepend APEX dirs to LD_LIBRARY_PATH before loading libart#1222

Merged
oleavr merged 2 commits intofrida:mainfrom
sam0holix:fix/android-apex-ld-library-path
Mar 24, 2026
Merged

android: prepend APEX dirs to LD_LIBRARY_PATH before loading libart#1222
oleavr merged 2 commits intofrida:mainfrom
sam0holix:fix/android-apex-ld-library-path

Conversation

@sam0holix
Copy link
Copy Markdown
Contributor

dlopen("libart.so") fails because the APEX mount paths are not in LD_LIBRARY_PATH and was causing the error:
unable to load libart.so: dlopen failed: ANDROID_DLEXT_USE_NAMESPACE is set but extinfo->library_namespace is null
This fix prepends the relevant APEX lib directories to LD_LIBRARY_PATH before the dlopen call, letting the linker resolve transitive dependencies automatically.

Tested on API 29 non-Google image.

Ref: This fixes frida/frida#3714 Issue 3714 on frida

@oleavr oleavr merged commit 1dc4435 into frida:main Mar 24, 2026
@oleavr
Copy link
Copy Markdown
Member

oleavr commented Mar 24, 2026

Thanks! 🙌

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

unable to load libart.so: dlopen failed: ANDROID_DLEXT_USE_NAMESPACE is set but extinfo->library_namespace is null

2 participants