make libffi.so.6 py2 tweak arch neutral

This commit is contained in:
Paul Fitzpatrick 2024-10-10 13:09:13 -04:00
parent 65f80ac7a1
commit 55346a33ed
No known key found for this signature in database
GPG Key ID: 07F16BF3214888F6

View File

@ -67,7 +67,8 @@ RUN \
build-essential libxml2-dev libxslt-dev python-dev zlib1g-dev && \
pip2 install wheel && \
pip2 install -r requirements.txt && \
pip2 install six
pip2 install six && \
find /usr/lib -iname "libffi.so.6*" -exec cp {} /usr/local/lib \;
################################################################################
## Sandbox collection stage
@ -111,8 +112,10 @@ COPY --from=collector-py2 /usr/local/lib/python2.7 /usr/local/lib/python2.7
RUN \
mkdir /etc/python2.7 && \
echo "import sys\nsys.path.append('/usr/local/lib/python2.7/site-packages')" > /etc/python2.7/sitecustomize.py
# Copy across an older libffi needed by python2
COPY --from=collector-py2 /usr/lib/x86_64-linux-gnu/libffi.so.6* /usr/lib/x86_64-linux-gnu/
# Copy across an older libffi library binary needed by python2.
# We moved it a bit sleazily to a predictable location to avoid awkward
# architecture-dependent logic.
COPY --from=collector-py2 /usr/local/lib/libffi.so.6* /usr/local/lib
# Copy python3 files.
COPY --from=collector-py3 /usr/local/bin/python3.11 /usr/bin/python3.11