Hi, I have recently tested to compile Open Babel 2.3.0 with CMake to use it with Mychem. The compilation and the installation work fine. However, the compilation of Mychem fails. I have tried with a cmake compiled Open Babel (v2.2.3) and the compilation of Mychem fails also with the following error: In function `OpenBabel::OBFingerprint::FindType(char const*)': /usr/local/include/openbabel-2.0/openbabel/fingerpint.h:43: undefined reference to `OpenBabel::OBFingerprint::Map()' In function `OBGroupContrib': /usr/local/include/openbabel-2.0/openbabel/groupcontrib.h:56: undefined reference to `vtable for OpenBabel::OBGroupContrib' ...
The compilation of Mychem works perfectly when using the Open Babel debian packages. If I remove the "visibility=hidden" in CMAKE_CXX_FLAGS, it works fine again. It seems that using a virtual function and a visibility set to hidden does not work properly. I've found the following info : " If you're linking one .so to another, yet one more possibility is compiling with "-fvisibility=hidden" in gcc or g++. If both .so files were built with "- fvisibility=hidden" and the key method is not in the same .so as another of the virtual function's implementations, the latter won't see the vtable or typeinfo of the former. To the linker, this looks like an unimplemented virtual function " It may be safe to remove visibility=hidden from CMakeLists.txt ? Debian builds use by default the autotools, that are not using the visibility parameter (therefore, it works perfectly). Cheers, Jerome ------------------------------------------------------------------------------ Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl _______________________________________________ OpenBabel-Devel mailing list OpenBabel-Devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/openbabel-devel