Error when building the chat simple for Android

asked 2014-05-15 08:52:39 -0700

tarek hentati gravatar image

When I 'm building the chat sample for Android I 'm using the ndk-build to compile the source code but i have the following error :

In file included from /home/dev15/alljoyn/core/alljoyn/alljoyn_core/inc/alljoyn/BusAttachment.h:34:0, from jni/Chat_jni.cpp:18: /home/dev15/alljoyn/core/alljoyn/alljoyn_core/inc/alljoyn/BusObject.h: In member function 'virtual QStatus ajn::BusObject::Get(char const, char const, ajn::MsgArg&)': /home/dev15/alljoyn/core/alljoyn/alljoyn_core/inc/alljoyn/BusObject.h:486:90: error: 'ER_BUS_NO_SUCH_PROPERTY' was not declared in this scope /home/dev15/alljoyn/core/alljoyn/alljoyn_core/inc/alljoyn/BusObject.h: In member function 'virtual QStatus ajn::BusObject::Set(char const, char const, ajn::MsgArg&)': /home/dev15/alljoyn/core/alljoyn/alljoyn_core/inc/alljoyn/BusObject.h:517:90: error: 'ER_BUS_NO_SUCH_PROPERTY' was not declared in this scope jni/Chat_jni.cpp: In constructor 'ChatObject::ChatObject(ajn::BusAttachment&, char const, JavaVM, jobject)': jni/Chat_jni.cpp:119:121: warning: 'ajn::BusObject::BusObject(ajn::BusAttachment&, char const, bool)' is deprecated (declared at /home/dev15/alljoyn/core/alljoyn/alljoyn_core/inc/alljoyn/BusObject.h:149) [-Wdeprecated-declarations] make: * [obj/local/armeabi-v7a/objs-debug/Chat/Chat_jni.o] Error 1*

i must add variables to the commande ndk-build to declare the BusObject !!?

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted

answered 2014-05-16 11:14:02 -0700

bspencer gravatar image

Just to start off, if you do not need to use C++ software (jni code) in your Android application then you can use the Java Language binding and write your Android application in Dalvik using the AllJoyn APIs and samples. AllJoyn allows for data marshaling, so applications written in C++ can talk to other ones written in Java or C, etc.

To asnwer the specific question, the reason it is not building and you have errors, is due building the sample from the AllJoyn Source instead of inside a compiled SDK. You can either compile the AllJoyn SDK for Android and then load up the projects inside the build folder that is created, or you can download the precompiled SDK and not worry about building it from source.

edit flag offensive delete publish link more
Login/Signup to Answer

Question Tools

1 follower


Asked: 2014-05-15 08:52:39 -0700

Seen: 108 times

Last updated: Aug 17 '14