From 2770415d93327d6c87894081ab2276f8aa66b18e Mon Sep 17 00:00:00 2001 From: Szabolcs Dombi Date: Sat, 10 Aug 2024 22:44:58 +0300 Subject: [PATCH] bump to version 3.0.0 --- .github/workflows/release.yml | 44 +++++++++++++++++++++-------------- setup.py | 19 ++++----------- 2 files changed, 30 insertions(+), 33 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index ab72fe4..514e665 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -5,36 +5,44 @@ on: jobs: release: - name: Build wheels on ${{ matrix.os }} + name: Build on ${{ matrix.os }} runs-on: ${{ matrix.os }} strategy: + fail-fast: false matrix: - os: [ubuntu-20.04, windows-2019, macos-11] + os: [ubuntu-latest, windows-latest, macos-13, macos-14] steps: - - uses: actions/checkout@v3 - - - name: setup - uses: actions/setup-python@v4 + - uses: actions/checkout@v4 + - uses: actions/setup-python@v5 with: - python-version: '3.11' - architecture: x64 - - - name: update - run: python -m pip install -U pip wheel setuptools + python-version: '3.12' - name: deps - run: python -m pip install cibuildwheel==2.16.2 + run: python -m pip install -U cibuildwheel build pip wheel setuptools - name: sdist - if: matrix.os == 'ubuntu-20.04' - run: python setup.py sdist -d package + run: python -m build --sdist --outdir package + if: matrix.os == 'ubuntu-latest' - name: wheels run: python -m cibuildwheel --output-dir package + env: + CIBW_PROJECT_REQUIRES_PYTHON: ">=3.8" + + - uses: actions/upload-artifact@v4 + with: + name: package-${{ matrix.os }} + path: package/* + + merge: + name: Merge Artifacts + runs-on: ubuntu-latest + needs: + - release - - name: upload - uses: actions/upload-artifact@v3 + steps: + - uses: actions/upload-artifact/merge@v4 with: - name: package - path: package + name: glcontext-3.0.0 + delete-merged: true diff --git a/setup.py b/setup.py index 10e6ab3..aae1fb6 100644 --- a/setup.py +++ b/setup.py @@ -1,5 +1,6 @@ import platform import sys + from setuptools import Extension, setup PLATFORMS = {'windows', 'linux', 'darwin'} @@ -13,18 +14,6 @@ if target not in PLATFORMS: target = 'linux' -if target == 'darwin': - import os - - if sys.version_info[:2] < (3, 12): - from distutils.sysconfig import get_config_var - from distutils.version import LooseVersion - if 'MACOSX_DEPLOYMENT_TARGET' not in os.environ: - current_system = LooseVersion(platform.mac_ver()[0]) - python_target = LooseVersion(get_config_var('MACOSX_DEPLOYMENT_TARGET')) - if python_target < '10.9' and current_system >= '10.9': - os.environ['MACOSX_DEPLOYMENT_TARGET'] = '10.9' - wgl = Extension( name='glcontext.wgl', sources=['glcontext/wgl.cpp'], @@ -90,13 +79,13 @@ setup( name='glcontext', - version='2.5.0', - description='Portable OpenGL Context', + version='3.0.0', + description='Portable Headless OpenGL Context', long_description=open('README.md', encoding='utf-8').read(), long_description_content_type='text/markdown', url='https://github.com/moderngl/glcontext', author='Szabolcs Dombi', - author_email='cprogrammer1994@gmail.com', + author_email='szabolcs@szabolcsdombi.com', license='MIT', platforms=['any'], packages=['glcontext'],