Jsoncpp version in Maya 2016 ext 2

Jsoncpp version in Maya 2016 ext 2

Anonymous
Not applicable
693 Views
3 Replies
Message 1 of 4

Jsoncpp version in Maya 2016 ext 2

Anonymous
Not applicable

Hello,

 

We are using jsoncpp in our maya plugin. Now, we are switching to Maya 2016 ext 2. But our plugin crashes due to inconsistent jsoncpp versions between our plugin and Maya. What is the correct version of jsoncpp to be used in our plugin?

 

Thank you, Pavel.

 

0 Likes
694 Views
3 Replies
Replies (3)
Message 2 of 4

cheng_xi_li
Autodesk Support
Autodesk Support

Hi pavel,

 

It should be jsoncpp v0.5.

 

You can find it in the About Maya dialog.

 

Yours,

Li

0 Likes
Message 3 of 4

Anonymous
Not applicable

It is still crashing when i used jsoncpp v0.5. Here is my call stack:

 

#1 __assert_fail in /lib/x86_64-linux-gnu/libc.so.6
#2 Json::Value::Value(Json::Value const&) in /maya-install-path/lib/libFoundation.so
#3 std::pair<Json::Value::CZString const, Json::Value>::pair(Json::Value::CZString const&, Json::Value const&) in /maya-install-path/lib/libFoundation.so
#4 Json::Value::resolveReference(char const*, char const*) in /maya-install-path/lib/libFoundation.so
#5 Json::Value::operator[](char const*) in /maya-install-path/lib/libFoundation.so
#6 myFunction() /my-plugin-install-path/libMyPlugin.so

 

Jsoncpp v0.5 is probably not a correct version. For example symbol Json::Value::resolveReference(char const*, char const*) is not present in jsoncpp v0.5 but libFoundation.so contains it. Jsoncpp v0.5 contains different symbol -- Json::Value::resolveReference(char const*, bool). I think that Maya uses some newer version of jsoncpp.

 

Unfortunately, About Maya dialog does not mention jsoncpp at all 😞

 

Do you please know the compatible version of jsoncpp to be used in my plugin?

 

Thank you.

 

0 Likes
Message 4 of 4

cheng_xi_li
Autodesk Support
Autodesk Support

Hi pavel, 

 

You can find the version of Jsoncpp at the end of About Maya.

 

I've checked our code, I didn't find the definition of resolveReference(char const*, char const*) in our code.

 

Can you try to compile your plugin with flag -Wl,-Bsymbolic? It turns off symbol preemption in the library to which it was applied. As a result, your plugin always use its own instance.

 

Yours,

Li

0 Likes