Skip to content

Commit

Permalink
Attempt to build stable ABI wheels
Browse files Browse the repository at this point in the history
  • Loading branch information
tiran committed Sep 28, 2021
1 parent 4f587cb commit c584b0d
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 9 deletions.
4 changes: 1 addition & 3 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ jobs:
os:
- ubuntu-latest
python-version:
- 3.5
- 3.6
- 3.7
- 3.8
Expand Down Expand Up @@ -47,7 +46,6 @@ jobs:
os:
- macos-latest
python-version:
- 3.5
- 3.6
- 3.7
- 3.8
Expand Down Expand Up @@ -82,7 +80,6 @@ jobs:
os:
- windows-latest
python-version:
- 3.5
- 3.6
- 3.7
- 3.8
Expand Down Expand Up @@ -147,6 +144,7 @@ jobs:
env:
WRAPT_INSTALL_EXTENSIONS: true # Require extensions.
CIBW_SKIP: pp* # Skip wheels for PyPy.
CIBW_BUILD: cp36-* # only build on 3.6 for stable cp36-abi3
- uses: actions/upload-artifact@v2
with:
name: dist
Expand Down
6 changes: 2 additions & 4 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ classifiers =
Development Status :: 5 - Production/Stable
License :: OSI Approved :: BSD License
Programming Language :: Python :: 3
Programming Language :: Python :: 3.5
Programming Language :: Python :: 3.6
Programming Language :: Python :: 3.7
Programming Language :: Python :: 3.8
Expand All @@ -32,7 +31,7 @@ project_urls =

[options]
zip_safe = false
python_requires = >= 3.5
python_requires = >= 3.6
packages = find:
package_dir =
=src
Expand All @@ -45,6 +44,7 @@ where=src

[bdist_wheel]
universal = false
py_limited_api=cp36

# --- Test and coverage configuration ------------------------------------------

Expand Down Expand Up @@ -74,13 +74,11 @@ envlist =

[gh-actions]
python =
3.5: py35, py35-without-extensions, py35-install-extensions, py35-disable-extensions
3.6: py36, py36-without-extensions, py36-install-extensions, py36-disable-extensions
3.7: py37, py37-without-extensions, py37-install-extensions, py37-disable-extensions
3.8: py38, py38-without-extensions, py38-install-extensions, py38-disable-extensions
3.9: py39, py39-without-extensions, py39-install-extensions, py39-disable-extensions
3.10: py310, py310-without-extensions, py310-install-extensions, py310-disable-extensions
pypy-2.7: pypy-without-extensions
pypy-3.6: pypy-without-extensions
pypy-3.7: pypy-without-extensions

Expand Down
1 change: 1 addition & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
"wrapt._wrappers",
sources=["src/wrapt/_wrappers.c"],
optional=not force_extensions,
py_limited_api=True,
)
]

Expand Down
6 changes: 4 additions & 2 deletions src/wrapt/_wrappers.c
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
/* ------------------------------------------------------------------------- */

/* stable ABI Python >= 3.5 */
#define Py_LIMITED_API 0x03050000
#ifndef Py_LIMITED_API
/* stable ABI Python >= 3.6, keep in sync with setup.cfg py_limited_api */
#define Py_LIMITED_API 0x03060000
#endif

#include "Python.h"

Expand Down

0 comments on commit c584b0d

Please sign in to comment.