Skip to content

Commit

Permalink
updates QGIS building (#402)
Browse files Browse the repository at this point in the history
* updates QGIS building
---------
Co-authored-by: pveigadecamargo <pveigadecamargo@anl.gov>
  • Loading branch information
pedrocamargo committed Apr 26, 2023
1 parent 8670b9e commit 51adcfa
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 7 deletions.
1 change: 1 addition & 0 deletions .github/qgis_requirements.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,5 @@ def replace_in_file(file_path, text_orig, suffix):


replace_in_file("../requirements.txt", "numpy", "<1.22")
replace_in_file("../pyproject.toml", "numpy", "<1.22")
replace_in_file("../__version__.py", "{minor_version}", ".dev0")
13 changes: 8 additions & 5 deletions .github/workflows/build_artifacts_qgis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,6 @@ jobs:
python-version: ['3.9', '3.10']
architecture: ['x64']
os: [windows-latest, macos-latest]
include:
- os: macos-latest
CC: "gcc-12"
CXX: "g++-12"
steps:
- uses: actions/checkout@v3
- name: Set Python environment
Expand Down Expand Up @@ -62,7 +58,7 @@ jobs:
- name: Build
if: ${{matrix.os != 'macos-latest'}}
run: python setup.py bdist_wheel
run: python setup.py sdist bdist_wheel

- name: Stores artifacts along with the workflow result
uses: actions/upload-artifact@v3
Expand All @@ -77,3 +73,10 @@ jobs:
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
run: twine upload dist/*.whl

- name: Publish tar files
if: ${{ (github.event_name == 'release') && (env.HAS_SECRETS == 'true') && (matrix.python-version == '3.9') }}
env:
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
run: twine upload dist/*.gz
21 changes: 19 additions & 2 deletions .github/workflows/build_linux.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Build and upload Linux Python Package
name: Build and upload Linux Python Package (includes QGIS artifacts)

on: [pull_request, release]

Expand All @@ -19,7 +19,7 @@ jobs:
python -m pip install --upgrade pip wheel cffi setuptools twine
- name: Build manylinux Python wheels
uses: RalfG/python-wheels-manylinux-build@v0.7.0
uses: RalfG/python-wheels-manylinux-build@v0.7.1
with:
python-versions: 'cp37-cp37m cp38-cp38 cp39-cp39 cp310-cp310 cp311-cp311'
pip-wheel-args: '--no-deps'
Expand All @@ -29,6 +29,23 @@ jobs:
mkdir -p dist
cp -v ./*-manylinux*.whl dist/
- name: update versions to conform with QGIS
run: |
cd .github
python qgis_requirements.py
cd ..
- name: Build manylinux Python wheels
uses: RalfG/python-wheels-manylinux-build@v0.7.1
with:
python-versions: 'cp38-cp38 cp39-cp39 cp310-cp310'
pip-wheel-args: '--no-deps'

- name: Moves wheels
run: |
mkdir -p dist
cp -v ./*-manylinux*.whl dist/
- name: Stores artifacts along with the workflow result
if: ${{ github.event_name == 'push'}}
uses: actions/upload-artifact@v3
Expand Down

0 comments on commit 51adcfa

Please sign in to comment.