Skip to content

Commit

Permalink
Migrate to pyproject.yaml based configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
flacjacket committed Sep 10, 2023
1 parent 4799e5a commit aada313
Show file tree
Hide file tree
Showing 3 changed files with 59 additions and 61 deletions.
22 changes: 11 additions & 11 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ jobs:
env:
PYTHON_VERSION: ${{ matrix.python-version }}
- name: Checkout repo
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Install dependencies
run: |
yum -y install \
Expand All @@ -160,10 +160,10 @@ jobs:
- name: Build wheels
run: |
python wlroots/ffi_build.py
python setup.py bdist_wheel
ls dist/
auditwheel show dist/pywlroots-*.whl
auditwheel repair --plat manylinux_2_28_x86_64 -w output_wheels dist/pywlroots-*.whl
pip wheel . -w whl
ls whl/
auditwheel show whl/pywlroots-*.whl
auditwheel repair --plat manylinux_2_28_x86_64 -w output_wheels whl/pywlroots-*.whl
- name: Upload wheel
uses: actions/upload-artifact@v3
with:
Expand Down Expand Up @@ -195,7 +195,7 @@ jobs:
PYTHON_VERSION: ${{ matrix.python-version }}
PP_VERSION: ${{ matrix.pypy-version }}
- name: Checkout repo
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Install dependencies
run: |
yum -y install \
Expand All @@ -214,10 +214,10 @@ jobs:
- name: Build wheels
run: |
python wlroots/ffi_build.py
python setup.py bdist_wheel
ls dist/
auditwheel show dist/pywlroots-*.whl
auditwheel repair --plat manylinux_2_28_x86_64 -w output_wheels dist/pywlroots-*.whl
pip wheel . -w whl
ls whl/
auditwheel show whl/pywlroots-*.whl
auditwheel repair --plat manylinux_2_28_x86_64 -w output_wheels whl/pywlroots-*.whl
- name: Upload wheel
uses: actions/upload-artifact@v3
with:
Expand Down Expand Up @@ -267,7 +267,7 @@ jobs:
python-version: "3.10"
steps:
- name: Checkout repo
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Setup Python
uses: actions/setup-python@v4
with:
Expand Down
49 changes: 48 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,54 @@
[build-system]
requires = [
"setuptools>=40.8.0",
"setuptools>=61.0.0",
"wheel",
"cffi>=1.12.0; python_implementation != 'PyPy'",
]
build-backend = "setuptools.build_meta"

[project]
name = "pywlroots"
description = "Python binding to the wlroots library using cffi"
authors = [{name = "Sean Vig", email = "[email protected]"}]
requires-python = ">=3.7"
license = {text = "MIT"}
readme = "README.rst"
classifiers = [
"Development Status :: 2 - Pre-Alpha",
"Operating System :: POSIX",
"Operating System :: POSIX :: Linux",
"Programming Language :: Python :: 3 :: Only",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: Implementation :: CPython",
"Programming Language :: Python :: Implementation :: PyPy",
"Topic :: Desktop Environment :: Window Managers",
"Topic :: Software Development :: Libraries",
]
dependencies = [
"cffi >= 1.12.0; python_implementation != 'PyPy'",
"pywayland >= 0.4.14",
"xkbcommon >= 0.2",
]
dynamic = ["version"]

[project.optional-dependencies]
test = ["pytest"]

[project.urls]
homepage = "https://github.com/flacjacket/pywlroots"

[tool.setuptools]
zip-safe = false

[tool.setuptools.packages.find]
include = ["wlroots*"]

[tool.setuptools.package-data]
wlroots = ["py.typed", "include/*.h"]

[tool.setuptools.dynamic]
version = {attr = "version.version"}
49 changes: 0 additions & 49 deletions setup.cfg
Original file line number Diff line number Diff line change
@@ -1,52 +1,3 @@
[metadata]
name = pywlroots
version = attr:version.version
url = https://github.com/flacjacket/pywlroots
license = MIT
license_files =
LICENSE
description = Python binding to the wlroots library using cffi
long_description = file: README.rst
long_description_content_type = text/x-rst
author = Sean Vig
author_email = [email protected]
classifiers =
Development Status :: 2 - Pre-Alpha
Operating System :: POSIX
Operating System :: POSIX :: Linux
Programming Language :: Python :: 3 :: Only
Programming Language :: Python :: 3.7
Programming Language :: Python :: 3.8
Programming Language :: Python :: 3.9
Programming Language :: Python :: 3.10
Programming Language :: Python :: Implementation :: CPython
Programming Language :: Python :: Implementation :: PyPy
Topic :: Desktop Environment :: Window Managers
Topic :: Software Development :: Libraries
project_urls =
Code = https://github.com/flacjacket/pywlroots/
Issue tracker = https://github.com/flacjacket/pywlroots/issues

[options]
packages = find:
python_requires >= 3.7
install_requires =
cffi >= 1.12.0
pywayland >= 0.4.14
xkbcommon >= 0.2
zip_safe = False

[options.extras_require]
test =
pytest

[options.package_data]
wlroots = py.typed, include/*.h

[options.packages.find]
include =
wlroots*

[flake8]
max-line-length = 120

Expand Down

0 comments on commit aada313

Please sign in to comment.