0

I went through the below links http://mirror.yongbok.net/linux/android/repository/external/mdnsresponder/ to get the apple mdns responder cross compiled on the android ndk . but I cloud not get the build it . got the below error .

make: Circular obj/local/armeabi/libmdnssd.so <- obj/local/armeabi/libmdnssd.so dependency dropped. SharedLibrary : libmdnssd.so arm-linux-androideabi-g++: ./obj/local/armeabi/libmdnssd.so: No such file or directory

If any one has cross built it for android pls help .

Edward Falk
  • 9,991
  • 11
  • 77
  • 112
indra
  • 832
  • 4
  • 17
  • 33

2 Answers2

1

There's an Android-friendly implementation of Bonjour called JmDNS. Feel free to download and integrate on the Java side.

Implementation is not exactly straightforward. There's the wrinkle with explicitly enabling multicasts over WiFi (look it up), and the JAR that's hosted on SourceForge is no good. But StackOverflow is full of guidance and samples.

Seva Alekseyev
  • 59,826
  • 25
  • 160
  • 281
  • I tried the jmdns but could't browse the subtypes I've registered my service with subtype using mdnsreponder(applebonjour) on my linux pc .I'm trying to browse the service using jmdns (here I've jmdns.jar) on my Galaxy phone .I registered service using the below command $dns-sd -R CAM _smartplace._tcp.,_wcam local 80 When I browse with out subtype in the service type list of jmdns I get the proper response.i.e ServiceInfo[] https = jmdns.list("_smartplace._tcp.local."); Hence but using avahi I am able to browse for the subtypes , hence I go with cross building mdnsresponder for andorid – indra Oct 23 '12 at 16:21
  • Once you get a `serviceAdded()` callback, call `requestServiceInfo()`. Then you'll get `serviceResolved()` which will list service details. – Seva Alekseyev Oct 23 '12 at 18:11
  • Hi, I am able do the service browse but not able to do the subtypes . may jmdns is incompitable with apple bonjour . because in bonjour we can browse the service by subtypes but in jmdns we gave to use the service type only . – indra Oct 27 '12 at 17:36
1

I think here you are looking for jmdns.listbysubtypes . You can try this for browsing subtypes

map mp = jmdns.listbysubtypes(_smartplace._tcp.local)

you can try this , once you get it then u can play with map object

user991353
  • 28
  • 3