File tree Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Original file line number Diff line number Diff line change @@ -33,6 +33,14 @@ tar -xzf Python-${CPYTHON_VERSION}.tgz
3333pushd Python-${CPYTHON_VERSION}
3434PREFIX=" /opt/_internal/cpython-${CPYTHON_VERSION} "
3535mkdir -p ${PREFIX} /lib
36+ if [ " ${AUDITWHEEL_POLICY} " == " manylinux2010" ]; then
37+ # The _ctypes stdlib module build started to fail with 3.10.0rc1
38+ # No clue what changed exactly yet
39+ # This workaround fixes the build
40+ LIBFFI_INCLUDEDIR=$( pkg-config --cflags-only-I libffi | tr -d ' [:space:]' )
41+ LIBFFI_INCLUDEDIR=${LIBFFI_INCLUDEDIR: 2}
42+ cp ${LIBFFI_INCLUDEDIR} /ffi.h ${LIBFFI_INCLUDEDIR} /ffitarget.h /usr/include/
43+ fi
3644# configure with hardening options only for the interpreter & stdlib C extensions
3745# do not change the default for user built extension (yet?)
3846./configure \
@@ -41,6 +49,9 @@ mkdir -p ${PREFIX}/lib
4149 --prefix=${PREFIX} --disable-shared --with-ensurepip=no > /dev/null
4250make > /dev/null
4351make install > /dev/null
52+ if [ " ${AUDITWHEEL_POLICY} " == " manylinux2010" ]; then
53+ rm -f /usr/include/ffi.h /usr/include/ffitarget.h
54+ fi
4455popd
4556rm -rf Python-${CPYTHON_VERSION} Python-${CPYTHON_VERSION} .tgz Python-${CPYTHON_VERSION} .tgz.asc
4657
You can’t perform that action at this time.
0 commit comments