Skip to content

Add a manylinux 'musllinux' variant#325

Merged
scoder merged 1 commit intolxml:masterfrom
noahp:noahp/add-musllinux-build
Oct 15, 2021
Merged

Add a manylinux 'musllinux' variant#325
scoder merged 1 commit intolxml:masterfrom
noahp:noahp/add-musllinux-build

Conversation

@noahp
Copy link
Copy Markdown
Contributor

@noahp noahp commented Sep 29, 2021

This is useful for alpine linux containers, to avoid needing a
multistage build to build + install the lxml package.

I tested it by building using make, then installing and using the
package in an alpine linux container:

❯ make wheel_musllinux_1_1_x86_64

❯ docker run \
  --rm \
  --workdir /tmp/workdir \
  --volume="$PWD:/tmp/workdir" \
  -t alpine \
  sh -c "
  set -e
  apk add python3
  # virtualenv
  python3 -m venv ~/.venv
  . ~/.venv/bin/activate
  # need a more recent version of pip for manylinux wheels
  pip install pip==21.2.4
  pip install wheelhouse/musllinux_1_1_x86_64/lxml-4.6.3-cp39-cp39-musllinux_1_1_x86_64.whl
  python -c 'import lxml; print(lxml.__version__)'
  "

This is useful for alpine linux containers, to avoid needing a
multistage build to build + install the lxml package.

I tested it by building using make, then installing and using the
package in an alpine linux container:

```bash
❯ make wheel_musllinux_1_1_x86_64

❯ docker run \
  --rm \
  --workdir /tmp/workdir \
  --volume="$PWD:/tmp/workdir" \
  -t alpine \
  sh -c "
  set -e
  apk add python3
  # virtualenv
  python3 -m venv ~/.venv
  . ~/.venv/bin/activate
  # need a more recent version of pip for manylinux wheels
  pip install pip==21.2.4
  pip install wheelhouse/musllinux_1_1_x86_64/lxml-4.6.3-cp39-cp39-musllinux_1_1_x86_64.whl
  python -c 'import lxml; print(lxml.__version__)'
  "
@scoder scoder merged commit 39eaef1 into lxml:master Oct 15, 2021
scoder pushed a commit that referenced this pull request Nov 1, 2021
This is useful for alpine linux containers, to avoid needing a
multistage build to build + install the lxml package.

I tested it by building using make, then installing and using the
package in an alpine linux container:

```bash
❯ make wheel_musllinux_1_1_x86_64

❯ docker run \
  --rm \
  --workdir /tmp/workdir \
  --volume="$PWD:/tmp/workdir" \
  -t alpine \
  sh -c "
  set -e
  apk add python3
  # virtualenv
  python3 -m venv ~/.venv
  . ~/.venv/bin/activate
  # need a more recent version of pip for manylinux wheels
  pip install pip==21.2.4
  pip install wheelhouse/musllinux_1_1_x86_64/lxml-4.6.3-cp39-cp39-musllinux_1_1_x86_64.whl
  python -c 'import lxml; print(lxml.__version__)'
  "
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

Successfully merging this pull request may close these issues.

2 participants