New issue 2622: building boost 1.64
https://bitbucket.org/pypy/pypy/issues/2622/building-boost-164
David Callahan:
Building boost 1.64 with PyPy yields the following error messages:
```
#!text
libs/python/src/exec.cpp: In function ‘boost::python::api::object
boost::python::exec_file(boost::python::str, boost::python::api::object,
boost::python::api::object)’:
libs/python/src/exec.cpp:89:30: error: ‘_Py_fopen’ was not declared in this
scope
FILE *fs = _Py_fopen(f, "r");
^
libs/python/src/wrapper.cpp: In member function ‘boost::python::override
boost::python::detail::wrapper_base::get\_override(const char*, PyTypeObject*)
const’:
libs/python/src/wrapper.cpp:28:50: error: ‘struct PyMethodObject’ has no member
named ‘im_self’
> && ((PyMethodObject*)m.get())->im_self == this->m_self
^
libs/python/src/wrapper.cpp:37:61: error: ‘struct PyMethodObject’ has no member
named ‘im_func’
if (borrowed_f != ((PyMethodObject*)m.get())->im_func)
```
In CPython 3.6.3 Py_fopen is declared in fileutils.h. Boost guards this
access with a test on Pyhton version >= 3.4.
Note, to build boost with PyPy, I modified the project-config.jam file built
by boostrap.sh by changing the "using" line for python to be:
```
#!text
using python
: 3.5 # Version
: /home/dcallahan/projects/pypy/install/bin/pypy3 # Python Path
: /home/dcallahan/projects/pypy/install/include # include path
: /home/dcallahan/projects/pypy/install/bin # lib path(s)
;
}
```
^
_______________________________________________
pypy-issue mailing list
[email protected]
https://mail.python.org/mailman/listinfo/pypy-issue