From 2f1d1849f269e4b60e0e3237dfb69a7094fa7799 Mon Sep 17 00:00:00 2001 From: Taco de Wolff Date: Sun, 12 May 2024 15:14:12 -0400 Subject: [PATCH] Update Python binding --- .github/workflows/python.yml | 5 ----- bindings/py/MANIFEST.in | 1 + bindings/py/pyproject.toml | 3 +++ bindings/py/setup.py | 1 - 4 files changed, 4 insertions(+), 6 deletions(-) create mode 100644 bindings/py/pyproject.toml diff --git a/.github/workflows/python.yml b/.github/workflows/python.yml index 3794bf7c07..59adbff598 100644 --- a/.github/workflows/python.yml +++ b/.github/workflows/python.yml @@ -184,11 +184,6 @@ jobs: with: python-version: '3.11' - - name: Debug - run: | - ls -la - ls -la bindings/py - - name: Build wheels uses: pypa/cibuildwheel@v2.17.0 with: diff --git a/bindings/py/MANIFEST.in b/bindings/py/MANIFEST.in index 4f38c23e5b..34ba7e7382 100644 --- a/bindings/py/MANIFEST.in +++ b/bindings/py/MANIFEST.in @@ -3,3 +3,4 @@ include minify.go go.mod go.sum include src/minify/minify.so include build_minify.py include py.typed +include pyproject.toml diff --git a/bindings/py/pyproject.toml b/bindings/py/pyproject.toml new file mode 100644 index 0000000000..cfe0de67a1 --- /dev/null +++ b/bindings/py/pyproject.toml @@ -0,0 +1,3 @@ +[build-system] +requires = ["setuptools>=42", "cffi>=1.0.0"] +build-backend = "setuptools.build_meta" diff --git a/bindings/py/setup.py b/bindings/py/setup.py index 0fb6552737..ef0341e131 100644 --- a/bindings/py/setup.py +++ b/bindings/py/setup.py @@ -65,7 +65,6 @@ def build_extension(self, ext: Extension): packages=["minify"], package_dir={"": "src"}, include_package_data=True, - setup_requires=["cffi>=1.0.0"], cffi_modules=["build_minify.py:ffi"], install_requires=["cffi>=1.0.0"], zip_safe=False,