[AMBER-Developers] Pytraj not compiling with Python 3.7

From: Gustavo Seabra <gustavo.seabra.gmail.com>
Date: Thu, 14 Nov 2019 13:15:53 -0500

Hi guys,

I'm trying to compile amber with my local (conda) python install, but I'm
getting this error from pytraj. Apparently it is related to some recent
change in the Cython behavior (see below). Does anyone here has any
experience with that?

My configuration:
- RedHat 8
- Python 3.7.5
- Cython 0.29.13
- Gcc 8.3.1

Thanks,
Gustavo.
-------

(base) [seabra.proline amber18]$ ./configure --with-python
/opt/anaconda3/bin/python gnu

[...]
(all works as expected)

(base) [seabra.proline amber18]$ make install

[...]

creating build/lib.linux-x86_64-3.7/pytraj/utils/css
copying pytraj/utils/css/oceans16.css ->
build/lib.linux-x86_64-3.7/pytraj/utils/css
running build_ext
building 'pytraj.core.c_core' extension
creating build/temp.linux-x86_64-3.7
creating build/temp.linux-x86_64-3.7/pytraj
creating build/temp.linux-x86_64-3.7/pytraj/core
gcc -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC
-I/opt/amber/amber18/AmberTools/src/cpptraj/src
-I/opt/amber/amber18/AmberTools/src/pytraj/pytraj
-I/opt/anaconda3/include/python3.7m -c pytraj/core/c_core.cpp -o
build/temp.linux-x86_64-3.7/pytraj/core/c_core.o -O0 -ggdb
-Wl,-rpath=/opt/amber/amber18/lib
cc1plus: warning: command line option '-Wstrict-prototypes' is valid for
C/ObjC but not for C++
pytraj/core/c_core.cpp: In function 'void __Pyx_ExceptionSave(PyObject**,
PyObject**, PyObject**)':
pytraj/core/c_core.cpp:26256:21: error: 'PyThreadState' {aka 'struct _ts'}
has no member named 'exc_type'; did you mean 'curexc_type'?
     *type = tstate->exc_type;
                     ^~~~~~~~
                     curexc_type
pytraj/core/c_core.cpp:26257:22: error: 'PyThreadState' {aka 'struct _ts'}
has no member named 'exc_value'; did you mean 'curexc_value'?
     *value = tstate->exc_value;
                      ^~~~~~~~~
                      curexc_value
pytraj/core/c_core.cpp:26258:19: error: 'PyThreadState' {aka 'struct _ts'}
has no member named 'exc_traceback'; did you mean 'curexc_traceback'?
     *tb = tstate->exc_traceback;
                   ^~~~~~~~~~~~~
                   curexc_traceback
pytraj/core/c_core.cpp: In function 'void __Pyx_ExceptionReset(PyObject*,
PyObject*, PyObject*)':
pytraj/core/c_core.cpp:26270:24: error: 'PyThreadState' {aka 'struct _ts'}
has no member named 'exc_type'; did you mean 'curexc_type'?
     tmp_type = tstate->exc_type;
                        ^~~~~~~~
                        curexc_type
pytraj/core/c_core.cpp:26271:25: error: 'PyThreadState' {aka 'struct _ts'}
has no member named 'exc_value'; did you mean 'curexc_value'?
     tmp_value = tstate->exc_value;
                         ^~~~~~~~~
                         curexc_value
pytraj/core/c_core.cpp:26272:22: error: 'PyThreadState' {aka 'struct _ts'}
has no member named 'exc_traceback'; did you mean 'curexc_traceback'?
     tmp_tb = tstate->exc_traceback;
                      ^~~~~~~~~~~~~
                      curexc_traceback
pytraj/core/c_core.cpp:26273:13: error: 'PyThreadState' {aka 'struct _ts'}
has no member named 'exc_type'; did you mean 'curexc_type'?
     tstate->exc_type = type;
             ^~~~~~~~
             curexc_type
pytraj/core/c_core.cpp:26274:13: error: 'PyThreadState' {aka 'struct _ts'}
has no member named 'exc_value'; did you mean 'curexc_value'?
     tstate->exc_value = value;
             ^~~~~~~~~
             curexc_value
pytraj/core/c_core.cpp:26275:13: error: 'PyThreadState' {aka 'struct _ts'}
has no member named 'exc_traceback'; did you mean 'curexc_traceback'?
     tstate->exc_traceback = tb;
             ^~~~~~~~~~~~~
             curexc_traceback
pytraj/core/c_core.cpp: In function 'int __Pyx_GetException(PyObject**,
PyObject**, PyObject**)':
pytraj/core/c_core.cpp:26318:24: error: 'PyThreadState' {aka 'struct _ts'}
has no member named 'exc_type'; did you mean 'curexc_type'?
     tmp_type = tstate->exc_type;
                        ^~~~~~~~
                        curexc_type
pytraj/core/c_core.cpp:26319:25: error: 'PyThreadState' {aka 'struct _ts'}
has no member named 'exc_value'; did you mean 'curexc_value'?
     tmp_value = tstate->exc_value;
                         ^~~~~~~~~
                         curexc_value
pytraj/core/c_core.cpp:26320:22: error: 'PyThreadState' {aka 'struct _ts'}
has no member named 'exc_traceback'; did you mean 'curexc_traceback'?
     tmp_tb = tstate->exc_traceback;
                      ^~~~~~~~~~~~~
                      curexc_traceback
pytraj/core/c_core.cpp:26321:13: error: 'PyThreadState' {aka 'struct _ts'}
has no member named 'exc_type'; did you mean 'curexc_type'?
     tstate->exc_type = local_type;
             ^~~~~~~~
             curexc_type
pytraj/core/c_core.cpp:26322:13: error: 'PyThreadState' {aka 'struct _ts'}
has no member named 'exc_value'; did you mean 'curexc_value'?
     tstate->exc_value = local_value;
             ^~~~~~~~~
             curexc_value
pytraj/core/c_core.cpp:26323:13: error: 'PyThreadState' {aka 'struct _ts'}
has no member named 'exc_traceback'; did you mean 'curexc_traceback'?
     tstate->exc_traceback = local_tb;
             ^~~~~~~~~~~~~
             curexc_traceback
pytraj/core/c_core.cpp: In function 'void __Pyx_ExceptionSwap(PyObject**,
PyObject**, PyObject**)':
pytraj/core/c_core.cpp:26345:24: error: 'PyThreadState' {aka 'struct _ts'}
has no member named 'exc_type'; did you mean 'curexc_type'?
     tmp_type = tstate->exc_type;
                        ^~~~~~~~
                        curexc_type
pytraj/core/c_core.cpp:26346:25: error: 'PyThreadState' {aka 'struct _ts'}
has no member named 'exc_value'; did you mean 'curexc_value'?
     tmp_value = tstate->exc_value;
                         ^~~~~~~~~
                         curexc_value
pytraj/core/c_core.cpp:26347:22: error: 'PyThreadState' {aka 'struct _ts'}
has no member named 'exc_traceback'; did you mean 'curexc_traceback'?
     tmp_tb = tstate->exc_traceback;
                      ^~~~~~~~~~~~~
                      curexc_traceback
pytraj/core/c_core.cpp:26348:13: error: 'PyThreadState' {aka 'struct _ts'}
has no member named 'exc_type'; did you mean 'curexc_type'?
     tstate->exc_type = *type;
             ^~~~~~~~
             curexc_type
pytraj/core/c_core.cpp:26349:13: error: 'PyThreadState' {aka 'struct _ts'}
has no member named 'exc_value'; did you mean 'curexc_value'?
     tstate->exc_value = *value;
             ^~~~~~~~~
             curexc_value
pytraj/core/c_core.cpp:26350:13: error: 'PyThreadState' {aka 'struct _ts'}
has no member named 'exc_traceback'; did you mean 'curexc_traceback'?
     tstate->exc_traceback = *tb;
             ^~~~~~~~~~~~~
             curexc_traceback
pytraj/core/c_core.cpp: At global scope:
pytraj/core/c_core.cpp:6030:18: warning: 'PyObject*
__pyx_pw_6pytraj_4core_6c_core_8NameType_7__str__(PyObject*)' defined but
not used [-Wunused-function]
 static PyObject *__pyx_pw_6pytraj_4core_6c_core_8NameType_7__str__(PyObject
*__pyx_v_self) {
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
error: command 'gcc' failed with exit status 1
make[2]: *** [Makefile:508: pytraj] Error 1
make[2]: Leaving directory '/opt/amber/amber18/AmberTools/src'
make[1]: *** [Makefile:56: serial] Error 2
make[1]: Leaving directory '/opt/amber/amber18/AmberTools/src'
make: *** [Makefile:7: install] Error 2



_______________________________________________
AMBER-Developers mailing list
AMBER-Developers.ambermd.org
http://lists.ambermd.org/mailman/listinfo/amber-developers
Received on Thu Nov 14 2019 - 10:30:02 PST
Custom Search