Excellent! This seems to work. A second point is that I still need to set BABEL_DATADIR to the correct path when I use the conda package in Windows, unlike in Linux and Mac. This is a minor issue but It would be convenient if users do not need to mess with environment variables.
Thanks for your help, Asim From: Noel O'Boyle Sent: Wednesday, October 2, 2019 4:09 PM To: Asem Alenaizan Cc: Geoffrey Hutchison; openbabel-discuss@lists.sourceforge.net Subject: Re: [Open Babel] Using Openbabel with a New Package It took me a little while to figure it out, but try adding the following to your CMake file: add_definitions(-DUSING_DYNAMIC_LIBS) On Wed, 2 Oct 2019 at 12:34, Noel O'Boyle <baoille...@gmail.com> wrote: I will try and get some time to look at this. My only thought at the moment is that the Windows build has its own babelconfig.h; I forget the details at the moment, but you need to include that instead of the 'default' one. - Noel On Sun, 29 Sep 2019 at 19:51, Asem Alenaizan <alenaiz...@gmail.com> wrote: It seems the problem is not related to the conda package. Even when I compile openbabel myself and link to it, and compile my program with the same compiler, I still fail to find the force field. Is there a reason that this is the case? This is specific to windows. I did not find this issue for Linux and Mac. Asim From: Asem Alenaizan Sent: Friday, September 27, 2019 4:06 PM To: Geoffrey Hutchison Cc: Noel O'Boyle; openbabel-discuss@lists.sourceforge.net Subject: RE: [Open Babel] Using Openbabel with a New Package Setting BABEL_LIBDIR does not fix the problem. Asim From: Geoffrey Hutchison Sent: Friday, September 27, 2019 3:09 PM To: Asem Alenaizan Cc: Noel O'Boyle; openbabel-discuss@lists.sourceforge.net Subject: Re: [Open Babel] Using Openbabel with a New Package The program can be compiled and linked correctly against openbabel, but I cannot find the force field. Noel's question is whether you can use the standard command-line tools and convert files: obabel -L forcefields obabel -:CCCC -omol --gen3d Finding the plugins is done using the BABEL_LIBDIR environment variable: https://openbabel.org/docs/dev/Installation/install.html Hope that helps, -Geoff
_______________________________________________ OpenBabel-discuss mailing list OpenBabel-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/openbabel-discuss