diff --git a/.github/workflows/wheels.yml b/.github/workflows/wheels.yml index 72ce51e..446baf2 100644 --- a/.github/workflows/wheels.yml +++ b/.github/workflows/wheels.yml @@ -6,26 +6,37 @@ on: [workflow_dispatch] jobs: build_wheels: - name: Build wheels on ${{ matrix.os }} - runs-on: ${{ matrix.os }} + name: Build wheels on for ${{matrix.python.cp}}-${{ matrix.buildplat.sys }} + runs-on: ${{ matrix.buildplat.runs_on }} strategy: matrix: - os: [ubuntu-20.04, macOS-latest] + buildplat: + - { runs_on: ubuntu-20.04, sys: manylinux, arch: x86_64, benv: "" } + - { runs_on: macos-12, sys: macosx, arch: x86_64, benv: "12.0" } + - { runs_on: macos-14, sys: macosx, arch: arm64, benv: "14.0" } + python: + - { cp: "cp39", rel: "3.9" } + - { cp: "cp310", rel: "3.10" } + - { cp: "cp311", rel: "3.11" } + - { cp: "cp312", rel: "3.12" } steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4.1.1 # Used to host cibuildwheel - - uses: actions/setup-python@v3 + - uses: actions/setup-python@v5 + with: + python-version: 3.11 - name: Install cibuildwheel run: python -m pip install cibuildwheel - - name: Build wheels + - name: Build wheels (Linux) + if: ${{ runner.os != 'macOS' }} run: python -m cibuildwheel --output-dir wheelhouse env: + CIBW_BUILD: ${{ matrix.python.cp }}-${{ matrix.buildplat.sys }}* CIBW_ARCHS_LINUX: "x86_64" - CIBW_ARCHS_MACOS: "x86_64" CIBW_BEFORE_ALL_LINUX: > if command -v apt-get; then apt-get -y git libicu-dev libxml2-dev libexttextcat-dev libxslt1-dev libbz2-dev zlib1g-dev autoconf automake autoconf-archive libtool autotools-dev gcc g++ make @@ -37,12 +48,21 @@ jobs: rsync -av --ignore-existing /usr/share/aclocal/*.m4 /usr/local/share/aclocal/ fi && ./build-deps.sh + CIBW_MANYLINUX_X86_64_IMAGE: quay.io/pypa/manylinux2014_x86_64 + CIBW_SKIP: "*-win* *-manylinux_i686 pp*" + + - name: Build wheels (macOS) + if: ${{ runner.os == 'macOS' }} + run: python -m cibuildwheel --output-dir wheelhouse + env: + CIBW_BUILD: ${{ matrix.python.cp }}-${{ matrix.buildplat.sys }}* + CIBW_ARCHS: ${{ matrix.buildplat.arch }} + CIBW_ENVIRONMENT: "MACOSX_DEPLOYMENT_TARGET=${{ matrix.buildplat.benv }}" CIBW_BEFORE_ALL_MACOS: > brew tap fbkarsdorp/homebrew-lamachine && brew install ucto - CIBW_MANYLINUX_X86_64_IMAGE: quay.io/pypa/manylinux2014_x86_64 - CIBW_SKIP: "*-win* *-manylinux_i686 pp*" - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 with: + name: ${{matrix.python.cp}}-${{matrix.buildplat.sys}}-${{matrix.buildplat.arch}} path: ./wheelhouse/*.whl diff --git a/setup.py b/setup.py index 11f81ac..607a3ac 100755 --- a/setup.py +++ b/setup.py @@ -32,9 +32,6 @@ libdirs.append("/usr/local/opt/libxml2/lib") includedirs.append("/usr/local/opt/libxml2/include") includedirs.append("/usr/local/opt/libxml2/include/libxml2") - includedirs.append("/usr/local/opt/ticcutils/include") - includedirs.append("/usr/local/opt/libfolia/include") - includedirs.append("/usr/local/opt/ucto/include") #libdirs.append("/usr/local/opt/libtextcat/lib") #includedirs.append("/usr/local/opt/libtextcat/include/libtextcat")