Created
January 3, 2020 11:30
-
-
Save mmaslowskicc/7485e795e3c8fec873515981293fd17c to your computer and use it in GitHub Desktop.
Minimal example for building platform-dependent wheels on PyPy using Poetry
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# No-op file needed so Poetry builds a platform-dependent wheel. | |
def build(setup_kwargs): | |
pass |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM pypy:3.6-slim | |
# Install dependencies of C libraries in dependencies and Poetry. | |
RUN set -e \ | |
&& apt-get update \ | |
&& apt-get install -y build-essential libssl-dev \ | |
&& pip install poetry==1.0.0 | |
# Add sample code. | |
COPY pyproject.toml poetry.lock build.py /app/ | |
RUN set -e \ | |
&& mkdir -p /app/src \ | |
&& touch /app/src/wheeltagtest.py | |
WORKDIR /app | |
# Build. | |
RUN poetry build | |
# Install the wheel. | |
RUN poetry run pip install dist/*.whl |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package = [] | |
[metadata] | |
content-hash = "115cf985d932e9bf5f540555bbdd75decbb62cac81e399375fc19f6277f8c1d8" | |
python-versions = "*" | |
[metadata.files] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[tool.poetry] | |
name = "wheeltagtest" | |
version = "0.1.0" | |
description = "" | |
authors = ["Anonymous"] | |
build = "build.py" | |
[build-system] | |
requires = ["poetry>=0.12"] | |
build-backend = "poetry.masonry.api" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment