Skip to content

Commit a7bfe06

Browse files
committed
Build lxml from source for cp315 on manylinux2014
lxml 6.1.3 ships no cp315 manylinux2014_x86_64 wheel, so pip falls back to the sdist, which fails without libxml2/libxslt dev packages. For this combination only, build lxml with STATIC_DEPS using the same libxml2 and libxslt versions xmlsec links. Remove once lxml publishes the wheel.
1 parent a905c61 commit a7bfe06

2 files changed

Lines changed: 13 additions & 0 deletions

File tree

‎.github/scripts/manylinux_build_and_test.sh‎

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,17 @@ case "$MANYLINUX_IMAGE" in
2626
;;
2727
esac
2828

29+
# Step: Build lxml from source with static deps (temporary)
30+
# TODO: remove once lxml publishes cp315 manylinux2014_x86_64 wheels.
31+
echo "== [container] Step: Configure lxml static build (cp315 manylinux2014 only) =="
32+
case "$PY_ABI/$MANYLINUX_IMAGE" in
33+
cp315-*/manylinux2014_*)
34+
export STATIC_DEPS=true
35+
export LIBXML2_VERSION="${LIBXML2_VERSION:?}" LIBXSLT_VERSION="${LIBXSLT_VERSION:?}"
36+
echo "STATIC_DEPS=$STATIC_DEPS LIBXML2_VERSION=$LIBXML2_VERSION LIBXSLT_VERSION=$LIBXSLT_VERSION"
37+
;;
38+
esac
39+
2940
# Step: Install python build dependencies
3041
echo "== [container] Step: Install python build dependencies =="
3142
/opt/python/${PY_ABI}/bin/pip install --upgrade pip setuptools wheel build 'setuptools_scm>=8'

‎.github/workflows/manylinux.yml‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,8 @@ jobs:
6161
-e PYXMLSEC_STATIC_DEPS \
6262
-e PY_ABI \
6363
-e MANYLINUX_IMAGE \
64+
-e LIBXML2_VERSION \
65+
-e LIBXSLT_VERSION \
6466
-e HOST_UID="$(id -u)" \
6567
-e HOST_GID="$(id -g)" \
6668
"quay.io/pypa/${MANYLINUX_IMAGE}" \

0 commit comments

Comments
 (0)