Hi Pankaj Jha,
We will need a little more information to help.
1. Python 3.6 or Python 2.7? You list both in your email.
2. On a clean build, can you provide the output from running cmake.
A potential problem is the old version of SWIG. If I were you I would
download and compile the latest one (you can install it locally), and use
-DSWIG_EXECUTABLE=whatever to point to the install location.
Regards,
- Noel
On 3 April 2018 at 06:05, Kumar Jha, Pankaj <pankaj.kumar...@astrazeneca.com
> wrote:
> Hi,
>
>
>
> I am trying to compile Openbabel – 2.4.1 with Python-3.6.3
>
> I have configured this with CMake-3.7.2, Python-2.7.13, libxml2-2.9.1,
> Eigen-3.2.8, zlib-1.2.11, SWIG-2.0.12, Java-1.8.0 and GCC-6.3.0.
>
>
>
> I have used cmake with following options:
>
> cmake ../openbabel-2.4.1 -DCMAKE_INSTALL_PREFIX=~/openbabel/2.4.1
> -DRUN_SWIG=ON -DPYTHON_BINDINGS=ON -DJAVA_BINDINGS=ON
>
>
>
> I am getting error while compiling it as following:
>
>
>
> [ 99%] Built target test_runner
>
> Scanning dependencies of target bindings_python
>
> [ 99%] Building CXX object scripts/CMakeFiles/bindings_
> python.dir/python/openbabel-python.cpp.o
>
> /home/pkj/test/openbabel/openbabel-2.4.1/scripts/python/openbabel-python.cpp:
> In function ‘PyObject* _wrap_OBForceField_DiverseConfGen__SWIG_0(PyObject*,
> int, PyObject**)’:
>
> /home/pkj/test/openbabel/openbabel-2.4.1/scripts/
> python/openbabel-python.cpp:34521:61: error: ‘class
> OpenBabel::OBForceField’ has no member named ‘DiverseConfGen’
>
> arg5 = static_cast< bool >(val5); result =
> (int)(arg1)->DiverseConfGen(arg2,arg3,arg4,arg5);
>
>
> ^~~~~~~~~~~~~~
>
> /home/pkj/test/openbabel/openbabel-2.4.1/scripts/python/openbabel-python.cpp:
> In function ‘PyObject* _wrap_OBForceField_DiverseConfGen__SWIG_1(PyObject*,
> int, PyObject**)’:
>
> /home/pkj/test/openbabel/openbabel-2.4.1/scripts/
> python/openbabel-python.cpp:34536:63: error: ‘class
> OpenBabel::OBForceField’ has no member named ‘DiverseConfGen’
>
> arg4 = static_cast< double >(val4); result =
> (int)(arg1)->DiverseConfGen(arg2,arg3,arg4);
>
>
> ^~~~~~~~~~~~~~
>
> /home/pkj/test/openbabel/openbabel-2.4.1/scripts/python/openbabel-python.cpp:
> In function ‘PyObject* _wrap_OBForceField_DiverseConfGen__SWIG_2(PyObject*,
> int, PyObject**)’:
>
> /home/pkj/test/openbabel/openbabel-2.4.1/scripts/
> python/openbabel-python.cpp:34549:69: error: ‘class
> OpenBabel::OBForceField’ has no member named ‘DiverseConfGen’
>
> arg3 = static_cast< unsigned int >(val3); result =
> (int)(arg1)->DiverseConfGen(arg2,arg3);
>
>
> ^~~~~~~~~~~~~~
>
> /home/pkj/test/openbabel/openbabel-2.4.1/scripts/python/openbabel-python.cpp:
> In function ‘PyObject* _wrap_OBForceField_DiverseConfGen__SWIG_3(PyObject*,
> int, PyObject**)’:
>
> /home/pkj/test/openbabel/openbabel-2.4.1/scripts/
> python/openbabel-python.cpp:34559:63: error: ‘class
> OpenBabel::OBForceField’ has no member named ‘DiverseConfGen’
>
> arg2 = static_cast< double >(val2); result =
> (int)(arg1)->DiverseConfGen(arg2);
>
>
> ^~~~~~~~~~~~~~
>
> make[2]: ***
> [scripts/CMakeFiles/bindings_python.dir/python/openbabel-python.cpp.o]
> Error 1
>
> make[1]: *** [scripts/CMakeFiles/bindings_python.dir/all] Error 2
>
> make: *** [all] Error 2
>
>
>
>
>
> I don’t get any error if I remove -DPYTHON_BINDINGS=ON but then I don’t
> get 2 executables generated including obrms.
>
> Could anyone please let me know what could be the possible reason for this
> python binding failure.
>
>
>
> Thanks & Regards,
>
> Pankaj Jha
>
>
> ------------------------------
>
> *Confidentiality Notice: *This message is private and may contain
> confidential and proprietary information. If you have received this message
> in error, please notify us and remove it from your system and note that you
> must not copy, distribute or take any action in reliance on it. Any
> unauthorized use or disclosure of the contents of this message is not
> permitted and may be unlawful.
>
>
> ------------------------------------------------------------
> ------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> OpenBabel-discuss mailing list
> OpenBabel-discuss@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/openbabel-discuss
>
>
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
OpenBabel-discuss mailing list
OpenBabel-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openbabel-discuss