diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index bd492de..1c25b60 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -17,11 +17,12 @@ env: jobs: build_wheels: - name: Build wheels on ${{ matrix.os }} + name: Build wheels on ${{ matrix.os }} with python ${{ matrix.python-version }} runs-on: ${{ matrix.os }} strategy: matrix: os: [ubuntu-18.04, macos-latest, windows-latest] + python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"] steps: - uses: actions/checkout@v2 @@ -31,7 +32,7 @@ jobs: - uses: actions/setup-python@v2 name: Install Python with: - python-version: 3.8 + python-version: ${{ matrix.python-version }} - uses: ilammy/msvc-dev-cmd@v1 with: diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 204c40c..0e6f137 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -7,7 +7,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - python-version: [3.8] + python-version: [3.13] steps: - uses: actions/checkout@v2 diff --git a/.gitmodules b/.gitmodules index 43c83db..fcf8742 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,3 +1,3 @@ -[submodule "poppler"] +[submodule "lib/poppler"] path = lib/poppler - url = https://github.com/freedesktop/poppler + url = https://gitlab.freedesktop.org/poppler/poppler.git diff --git a/setup.py b/setup.py index 68cf94c..771ab97 100644 --- a/setup.py +++ b/setup.py @@ -1,14 +1,14 @@ # -*- coding: utf-8 -*- -import os -import sys import glob +import os import shutil +import sys import pybind11 +import setuptools +from setuptools import Extension, find_packages, setup from setuptools.command.build_ext import build_ext -from setuptools import setup, Extension, find_packages - here = os.path.abspath(os.path.dirname(__file__)) about = {} @@ -36,7 +36,7 @@ if sys.platform == "win32": # https://docs.python.org/3/library/platform.html#platform.architecture - x = "x64" if sys.maxsize > 2 ** 32 else "x86" + x = "x64" if sys.maxsize > 2**32 else "x86" poppler_dir = os.path.join(os.getcwd(), "lib", "poppler") build_dir = os.path.join(poppler_dir, f"build_win_{x}") @@ -77,13 +77,14 @@ ), ] + # cf http://bugs.python.org/issue26689 def has_flag(compiler, flagname): """Return a boolean indicating whether a flag name is supported on the specified compiler. """ - import tempfile import os + import tempfile with tempfile.NamedTemporaryFile("w", suffix=".cpp", delete=False) as f: f.write("int main (int argc, char **argv) { return 0; }") @@ -177,9 +178,11 @@ def setup_package(): # Trove classifiers # Full list: https://pypi.python.org/pypi?%3Aaction=list_classifiers "License :: OSI Approved :: GNU General Public License v2 (GPLv2)", - "Programming Language :: Python :: 3.6", - "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 :: 3.12", + "Programming Language :: Python :: 3.13", ], cmdclass={"build_ext": BuildExt}, )