[pypy-issue] Issue #3131: scipy 1.4+ install: error: ‘PyModule_AddFunctions’ was not declared in this scope (pypy/pypy)

Jan Vesely issues-reply at bitbucket.org
Sun Dec 22 07:44:08 EST 2019


New issue 3131: scipy 1.4+ install: error: ‘PyModule_AddFunctions’ was not declared in this scope
https://bitbucket.org/pypy/pypy/issues/3131/scipy-14-install-error

Jan Vesely:

updating scipy to 1.4 results in:

```
  /var/tmp/pip-build-env-q588n5yp/overlay/site-packages/numpy/distutils/system_info.py:664: UserWarning: Specified path /var/tmp/pip-build-env-q588n5yp/overlay/site-packages/numpy/__init__.py/include is invalid.
    return self.get_paths(self.section, key)
  /var/tmp/pip-build-env-q588n5yp/overlay/site-packages/numpy/distutils/system_info.py:664: UserWarning: Specified path /usr/local/include/include is invalid.
    return self.get_paths(self.section, key)
  /var/tmp/pip-build-env-q588n5yp/overlay/site-packages/numpy/distutils/system_info.py:664: UserWarning: Specified path /usr/include/include is invalid.
    return self.get_paths(self.section, key)
  /var/tmp/pip-build-env-q588n5yp/overlay/site-packages/numpy/distutils/system_info.py:664: UserWarning: Specified path /home/user/pypy3-venv/include/include is invalid.
    return self.get_paths(self.section, key)
  error: Command "g++ -pthread -fPIC -DPOCKETFFT_PTHREADS -I/home/user/pypy3-venv/include/site/python3.6 -I/home/user/pypy3-venv/include/site/python3.6 -I/var/tmp/pip-build-env-q588n5yp/overlay/site-packages/numpy/core/include -I/home/user/pypy3-venv/include -I/usr/lib/pypy3.6/include -c scipy/fft/_pocketfft/pypocketfft.cxx -o build/temp.linux-x86_64-3.6/scipy/fft/_pocketfft/pypocketfft.o -MMD -MF build/temp.linux-x86_64-3.6/scipy/fft/_pocketfft/pypocketfft.o.d -std=c++14 -fvisibility=hidden" failed with exit status 1
  scipy/fft/_pocketfft/pypocketfft.cxx: In function ‘void pybind11_init_pypocketfft(pybind11::module&)’:
  scipy/fft/_pocketfft/pypocketfft.cxx:731:3: error: ‘PyModule_AddFunctions’ was not declared in this scope
    731 |   PyModule_AddFunctions(m.ptr(), good_size_meth);
        |   ^~~~~~~~~~~~~~~~~~~~~
  scipy/fft/_pocketfft/pypocketfft.cxx: In function ‘void pybind11_init_pypocketfft(pybind11::module&)’:
  scipy/fft/_pocketfft/pypocketfft.cxx:731:3: error: ‘PyModule_AddFunctions’ was not declared in this scope
    731 |   PyModule_AddFunctions(m.ptr(), good_size_meth);
```

  
the attached log is for:

```
$ pypy3 --version
Python 3.6.9 (5da45ced70e515f94686be0df47c59abd1348ebc, Nov 02 2019, 18:56:40)
[PyPy 7.2.0 with GCC 8.3.0]
```

but the same problem appears in:

```shell
$ python --version
Python 3.7.4 (47c4c0ed3274, Dec 20 2019, 17:37:49)
[PyPy 7.3.0-alpha0 with GCC 9.2.1 20190827 (Red Hat 9.2.1-1)]
```

and:

```
$ python --version
Python 3.6.9 (574325fb0c26, Dec 20 2019, 17:38:07)
[PyPy 7.3.1-alpha0 with GCC 9.2.1 20190827 (Red Hat 9.2.1-1)]
```

scipy 1.3.x works OK.

‌




More information about the pypy-issue mailing list