I have an existing c++/java project that works on linux, windows and android and I want to make it work on firefox OS (B2G) too. I have built binaries(daemon and client) of my project for FFOS and tested them on command line using adb shell. The problem is how to access that daemon through user application using javascript.
Since FFOS uses HTML/JS/CSS for applications, one suggestion is to convert the whole project into javascript using 'emscripten' tool. But given the size and complexity of my project, this doesn't seem to work (lots of errors, missing header files etc). It uses some low-level functionality like creating a UDP packet, sending out multicast packets and listening-on and connecting-to a tcp/udp port; these features are lacking in javascript API (am i wrong?).
Another suggestion was to use Web IDL (requires modification of FFOS gecko engine) but I am not sure how it can help me in my scenario.
Any ideas/tips/suggestions would be appreciated. Thanks.