Skip to content

cffi fails to build in latest images #996

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
glandium opened this issue Feb 11, 2021 · 5 comments
Closed

cffi fails to build in latest images #996

glandium opened this issue Feb 11, 2021 · 5 comments

Comments

@glandium
Copy link

It used to build fine a few days ago, and is broken as of the latest images.

It seems the regression happened somewhere between 2021-01-24-91ce2b8 and 2021-02-06-93da623 for the manylinux2014 images and somewhere between 2021-02-06-3d322a5 and 2021-02-07-7816579 for the manylinux2010 images.

Example of failure log: https://github.com/indygreg/python-zstandard/pull/137/checks?check_run_id=1879152214

Cc: @indygreg

@glandium
Copy link
Author

The link apparently died. Here's an excerpt of the log:

   gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -DUSE__THREAD -DHAVE_SYNC_SYNCHRONIZE -I/usr/include/ffi -I/usr/include/libffi -I/opt/_internal/cpython-3.9.1/include/python3.9 -c c/_cffi_backend.c -o build/temp.linux-i686-3.9/c/_cffi_backend.o
    c/_cffi_backend.c:15:10: fatal error: ffi.h: No such file or directory
     #include <ffi.h>
              ^~~~~~~
    compilation terminated.
    error: command '/opt/rh/devtoolset-8/root/usr/bin/gcc' failed with exit code 1
    ----------------------------------------
    Running setup.py install for cffi: finished with status 'error'

It seems libffi headers are not there anymore, while they're apparently useful to build cffi modules with python 3.9.

@glandium glandium changed the title python-zstandard fails to build in latest images cffi fails to build in latest images Feb 13, 2021
@glandium
Copy link
Author

Earlier in the log:

Collecting cffi==1.13.2

and cffi 1.13.2 doesn't have a wheel for python 3.9. So the problem is really that cffi itself doesn't build in the new images.

@mayeut
Copy link
Member

mayeut commented Feb 13, 2021

@glandium,

Thanks for the report.
Indeed, as a side-effect of #877, libffi-devel is not installed in the published images anymore.
Only development packages of libraries whitelisted in the various manylinux PEP are installed and are the only development packages one should assume are installed as noted in the README (Devel packages for all the libraries that PEP 571/599 allows you to assume are present on the host system).
That being said, it's still a regression for some users like yourself so, while I'd rather have python-zstandard fix its build not to assume presence of libffi-devel, I'm also not strictly against adding it back if other users are impacted.

@mayeut
Copy link
Member

mayeut commented Feb 13, 2021

fixed in python-zstandard: indygreg/python-zstandard#140

@mayeut mayeut closed this as completed Feb 13, 2021
@yuangu
Copy link

yuangu commented Nov 8, 2021

I have the same problem

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants