Re: [Open Babel] linking to libopenbabel

2012-05-11 Thread Geoff Hutchison
> Everything compiles without any errors. However, everytime I execute my > application and run into the function SetInAndOutFormats, the API returns the > following: > "Formats not available" Have you created an OBConversion object? The C++ constructor will load the formats. You may also need

[Open Babel] RE : linking to libopenbabel

2012-05-11 Thread Gaudreault, Francis
Hi Geoff, Yes I have my OBConversion object. Here is the code that compiles correctly: OpenBabel::OBConversion conv(&ifs,&ofs); if(!conv.SetInAndOutFormats(informat,"mol2")){ strcpy(error,"ERROR: OpenBabel: Formats not available\n"); return 0; } I havent heard of any environment variable

[Open Babel] linking to libopenbabel

2012-05-11 Thread Gaudreault, Francis
To whom it may concern, I am trying to dynamically link the library libopenbabel.dylib (Mac), libopenbabel.so (Linux) or openbabel-2.dll (Windows) to my application. The only API function I use is the following: OBConversion::SetInAndOutFormats that allows conversion between the different format