6

Has anyone succeeded in running the Java bindings for dbus on Android? All indications point at dbus already running as a process within the Android OS, but there is no official access point for them through the Java interface. Thanks in advance!

asked Oct 19, 2009 at 21:09

2 Answers 2

3

You shouldn't do this unless you're talking about your own bus talking to things you control. There's no guarantee that dbus will be available. According to the android mailing list, it's just an implementation detail that dbus is around at all, it's not guaranteed to be there, and might not be there in the future.

answered May 25, 2011 at 22:15

Comments

0

You can try using the dbus-java from the freedesktop project. I don't know if it works on android tough.

answered Oct 20, 2009 at 6:37

4 Comments

Thanks for the suggestion! I'd given that a try, but it requires a JNI implementation of Unix sockets to run. That requires pushing a C library onto Android, which I am not quite sure how to do. I've seen that pushing simple programs is possible, but I haven't seen a full library pushed. Or perhaps I'm just not runinng the make properly.
You can use TCP instead of unix-sockets, and then you have pure Java library
you'd need to modify the dbus library. There's nothing like a configuration option to build without unix sockets.
Android has always supported Unix domain sockets (at least to some degree) in Java via the LocalSocket class.

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.