Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Faiiled to build what use ndk_context project #201

Closed
oligamiq opened this issue Nov 27, 2023 · 3 comments
Closed

Faiiled to build what use ndk_context project #201

oligamiq opened this issue Nov 27, 2023 · 3 comments

Comments

@oligamiq
Copy link

cargo-apk, tauri, ndk-glue initialize ndk_context crate.
As far as I know, ndk_context crate is very important for android native api binding.
But this library is not, so my project run is failed.

Could you please support?

@fredszaq
Copy link
Collaborator

Hi @nziq53 !

Do you have some code somewhere I can take a look at ?

That being said, it looks like ndk_context needs a quite different approach from what we're doing with dinghy. ndk_context needs an android app VM to initialize whereas dinghy only spawns regular Linux processes on the target device.

Not sure the approach of spawning an app VM it something that is desirable for dinghy. If we do add it it should be behind a flag I guess. But then again we would in that case probably do the same thing that cargo apk / xbuild does.

@oligamiq
Copy link
Author

@fredszaq
Copy link
Collaborator

Hi @nziq53 ! We've discussed a bit with @kali about this and concluded that support for JVM applications is not something that seem wise to add inside dinghy, given that tools like cargo apk or xbuild already exist and do exactly that.

Dinghy first goal has always been to be able to test code written for posix like platforms on embedded platforms. In your use case the code you're writing is definitely expecting way more than a posix platform (ie it need to be run inside a process containing an android JVM). One implementation that could be done in dinghy could be to wrap cargo apk or xtools to support these use case, but we fail to see the added value this would bring compared to directly call those specialised tools.

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

No branches or pull requests

2 participants