![]() ![]() Another version may do these things again. ![]() Also, a library's initialization function can do things that should not happen twice. However, checking that can be very hard, especially if they pass the API object only as a member of another object. There will be a problem if they will pass this API's objects between them. Note: In some cases, there would be no problem with two or more different versions of the same API in a completely different parts of a program. When a std::string that has been created by Foo will be passed to Bar, Bar will think that this is an instance of its c++ library's std::string and then bad things can happen (they are a completely different objects). They both have a function that takes a std::string and uses it for something but they use a different c++ library. ![]() To understand why mixing two version of the same API is bad, consider this situation: There are two libraries: Foo and Bar. In libc++, this type's name is std::_1::pair. In our case, it happens because that libc++ developers intentionally changed the name of all of their symbols to prevent you (and save you) from mixing code from their library and code from a different one: myMod.so need a function that take an argument from the type. Otherwise - on computer that its boost-python has compiled with libc++ (or another c++ library), it will have a problem loading and running it. When boost-python is boost-python-libstdc++, it will work fine. In our case, the library myMod.so (compiled with libstdc++) need boost-python that compiled with libstdc++ ( boost-python-libstdc++ from now). The problem was caused by mixing objects that compiled with libc++ and object that compiled with libstdc++. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |