Skip to content
This repository has been archived by the owner on Jul 3, 2020. It is now read-only.

Including additional dynamic libraries #174

Open
torkleyy opened this issue Feb 10, 2018 · 4 comments
Open

Including additional dynamic libraries #174

torkleyy opened this issue Feb 10, 2018 · 4 comments

Comments

@torkleyy
Copy link

I'd like to include .so files for the vulkan validation layers (e.g. libVkLayer_core_validation.so) in my APK. How can I do that?

@hansihe
Copy link

hansihe commented Dec 14, 2019

I also need to do something like this. As I understand it, there was some support for this before, but that seems to have been removed?

I am sure I can cobble something together and make a PR, but if anyone more familiar with the project has a preferred way to implement this in mind, any comments would be greatly appreciated.

@katyo
Copy link
Contributor

katyo commented Jan 2, 2020

I have same issue with bindings which depends from bundled shared object.
Currently only libc++_shared.so can be packaged automatically when it used.

@katyo
Copy link
Contributor

katyo commented Jan 2, 2020

I think the optimal way to list all required shared objects (for packaging it together) using readelf, like the following:
https://github.com/rust-windowing/android-rs-glue/blob/096c6dd62dfa3e6c233f9ed3aafedfb9dab57871/cargo-apk/src/ops/build/compile.rs#L332-L353
Of course, we should read shared objects recursively and filter out android libraries (like libandroid.so, liblog.so, etc.)
I still don't find out how to get all libraries search paths from cargo.
The libraries search paths can be simply extracted from rustc args.

@katyo
Copy link
Contributor

katyo commented Jan 4, 2020

@torkleyy Can you test cargo-apk from my PR above? Or let me do it.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants