Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rtree Wheel Infrastructure #163

Merged
merged 134 commits into from
Dec 16, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
134 commits
Select commit Hold shift + click to select a range
73706f1
first pass
mikedh Apr 24, 2020
dd0110a
LSI install script
mikedh Apr 24, 2020
79c9eee
try curl
mikedh Apr 24, 2020
c427a0f
freaking sha256sum
mikedh Apr 24, 2020
c139750
update manylinux cmake
mikedh Apr 24, 2020
91721f8
get deps on mac
mikedh Apr 24, 2020
3b2535a
skip test for now
mikedh Apr 24, 2020
0bcdbb7
rerun actions
mikedh Aug 5, 2020
b57a17e
do some things to copy in shared library
mikedh Aug 5, 2020
78b435d
copy over shared library
mikedh Aug 5, 2020
aaf1c43
remove FileNotFoundError
mikedh Aug 5, 2020
71f6c08
remove non-linux for testing
mikedh Aug 5, 2020
3f0bd62
build with tests
mikedh Aug 5, 2020
6dcbd09
add numpy to test_requires
mikedh Aug 5, 2020
012de7e
skip unicode filenames on python 2
mikedh Aug 5, 2020
6a5b11a
try different comparison test
mikedh Aug 5, 2020
037f768
pass flake8
mikedh Aug 5, 2020
5c024fa
skip cp27m
mikedh Aug 11, 2020
f073a3e
missing wildcard
mikedh Aug 11, 2020
6ef4146
skip broken test on python 2
mikedh Aug 20, 2020
87fd037
test_index passing flake8
mikedh Aug 20, 2020
c190125
update finder and skip test
mikedh Aug 20, 2020
9e324dd
add back awful hack
mikedh Aug 20, 2020
3a41142
skip pypy builds
mikedh Aug 20, 2020
0e8fb1d
linux working add back windows and macos
mikedh Aug 20, 2020
fa2822a
try building on windows with same script
mikedh Aug 20, 2020
e418b8f
try bash scripting windows
mikedh Aug 20, 2020
6266870
add imports to init
mikedh Aug 21, 2020
1f469b0
make build dirs if they don't exist
mikedh Aug 21, 2020
b5e8231
check before makedirs
mikedh Aug 21, 2020
e9336a4
fix typo
mikedh Aug 21, 2020
f96b917
switch to batch file
mikedh Nov 3, 2020
9b6773c
batch
mikedh Nov 3, 2020
d51a347
install out of script
mikedh Nov 3, 2020
e950a6b
foolishly try make
mikedh Nov 3, 2020
8170e30
back
mikedh Nov 3, 2020
3b38a80
pip to batch
mikedh Nov 3, 2020
e1ecb73
make?
mikedh Nov 3, 2020
dad8987
remove more
mikedh Nov 3, 2020
79cd038
ninja
mikedh Nov 3, 2020
b896bc9
copy compiler
mikedh Nov 3, 2020
472befa
try clang
mikedh Nov 3, 2020
8194bf2
test whitespace
mikedh Nov 3, 2020
6548160
clang?
mikedh Nov 3, 2020
fd1bc9d
windows all use choco
mikedh Nov 3, 2020
f2c9563
flake8
mikedh Nov 3, 2020
1a565ec
clang-cl
mikedh Nov 3, 2020
aa14644
try gh clang
mikedh Nov 4, 2020
68b53b2
try relative path
mikedh Nov 4, 2020
42bcd4c
windows paths
mikedh Nov 4, 2020
a12f3f8
escape
mikedh Nov 4, 2020
964f6ba
convoluted llvm path
mikedh Nov 4, 2020
8204ff0
hard paths
mikedh Nov 4, 2020
7030473
set env in gh
mikedh Nov 4, 2020
caa7d4e
try fixing some cmake bugs
mikedh Nov 5, 2020
513c8f0
change working directory
mikedh Nov 5, 2020
1d5c0d3
cd doesnt work?
mikedh Nov 5, 2020
6607b6f
use batch path tomfoolery
mikedh Nov 5, 2020
60cdde0
try
mikedh Nov 11, 2020
465212f
try msbuild
mikedh Nov 11, 2020
d1b3ba5
copy dll
mikedh Nov 11, 2020
a3e67f0
windows finder logic
mikedh Nov 11, 2020
b1df646
typo
mikedh Nov 11, 2020
c1972a2
try again
mikedh Nov 11, 2020
402d318
finder logic
mikedh Nov 11, 2020
e45fefe
try script relative copy
mikedh Nov 11, 2020
9bcf108
use copy
mikedh Nov 11, 2020
38f8700
add debug dir
mikedh Nov 11, 2020
4557cb5
add debug prints
mikedh Nov 11, 2020
9b83b96
tuple
mikedh Nov 11, 2020
ef78270
build both 64 and 32?
mikedh Nov 11, 2020
b2a5482
try override
mikedh Nov 11, 2020
1390484
try release32?
mikedh Nov 16, 2020
72eef88
add force32
mikedh Nov 18, 2020
593179e
typo
mikedh Nov 19, 2020
db6176d
skip 32 bit builds on windows
mikedh Nov 19, 2020
b3365b7
re-enable other wheels
mikedh Nov 19, 2020
5e08a1e
typo
mikedh Nov 19, 2020
bb98266
tpr test
mikedh Nov 19, 2020
821a769
skip test_tpr on windows
mikedh Nov 19, 2020
c7eae26
try simpler copy strategy
mikedh Nov 21, 2020
23102ed
update copy
mikedh Nov 21, 2020
e350228
absolute paths
mikedh Nov 21, 2020
3153455
in too deep
mikedh Nov 21, 2020
0d05537
more paths
mikedh Nov 21, 2020
b9e6fbc
finder changes working locally
mikedh Nov 22, 2020
4ac0238
add repair_wheel override
mikedh Nov 22, 2020
c440155
yaml typo
mikedh Nov 22, 2020
4f8a0c7
mac uses bsd cp
mikedh Nov 22, 2020
5ab7fce
skip mac
mikedh Nov 22, 2020
c4dfb5d
move to lib
mikedh Nov 22, 2020
1baea90
explicit copy for macos
mikedh Nov 22, 2020
11d8183
pass in target location
mikedh Nov 22, 2020
7d983ba
what the heck
mikedh Nov 22, 2020
eb26c49
paths are hard
mikedh Nov 22, 2020
668f671
fix working copy
mikedh Nov 22, 2020
1d085e8
set search on mac
mikedh Nov 22, 2020
57e436d
try
mikedh Nov 22, 2020
b794381
try some magic
mikedh Nov 22, 2020
6d3416f
different
mikedh Nov 22, 2020
5616b54
static
mikedh Nov 22, 2020
2d94bb9
linker
mikedh Nov 23, 2020
0ca9e97
copy cmake
mikedh Nov 23, 2020
794bd58
remove arg
mikedh Nov 23, 2020
cf84146
try static build
mikedh Nov 23, 2020
51f9fae
try no rpath
mikedh Nov 23, 2020
5a2c979
renable wheel repair on mac
mikedh Nov 23, 2020
bcd0a8e
skip cleanup
mikedh Nov 23, 2020
3a483b1
skip test on mac for wheel debugging
mikedh Nov 23, 2020
e5f4f1f
fix path on windows
mikedh Nov 23, 2020
751c699
delocate args
mikedh Nov 23, 2020
c690a6c
fix extension
mikedh Nov 23, 2020
d9ee6b1
don't copy everything
mikedh Nov 23, 2020
5192a14
change copy for mac
mikedh Nov 23, 2020
418b843
delocate args
mikedh Dec 11, 2020
bda453c
get unrepaired wheel for testing
mikedh Dec 11, 2020
16115c7
more dylib
mikedh Dec 11, 2020
233f6c6
try manual dylib repair
mikedh Dec 14, 2020
e6a9a8e
remove build directories to make sure paths are OK
mikedh Dec 14, 2020
f6c0dd3
minor fixes
mikedh Dec 14, 2020
44dc80d
add windows search paths for conda
mikedh Dec 14, 2020
d1f4c33
add missed import
mikedh Dec 14, 2020
24e3f7f
install rtree in docs image
mikedh Dec 14, 2020
d7ed10f
docs pip3
mikedh Dec 14, 2020
fe43c2b
curl
mikedh Dec 14, 2020
71ac227
try python2 again
mikedh Dec 14, 2020
dd86f3a
apt
mikedh Dec 14, 2020
f586616
use apt spatial for docs
mikedh Dec 14, 2020
1768e2b
check windows/linux wheel repair
mikedh Dec 15, 2020
496162c
right
mikedh Dec 15, 2020
3e22b32
auditwheel
mikedh Dec 15, 2020
df5c93a
don't repair windows wheels
mikedh Dec 15, 2020
5a5db46
cd to test dir
mikedh Dec 15, 2020
7d0ed72
revert test command
mikedh Dec 15, 2020
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
153 changes: 5 additions & 148 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -78,126 +78,19 @@ jobs:
run: |
python3 -m pytest --doctest-modules rtree tests


# linux-wheel:
# name: manylinux Wheel ${{ matrix.python-root }}
#
# runs-on: ubuntu-latest
# strategy:
# matrix:
# python-version: ['3.6','3.7','3.8']
#
# steps:
# - uses: actions/checkout@v2
# - name: Build
# shell: bash -l {0}
# run: |
# docker run -v $(pwd):/src quay.io/pypa/manylinux1_x86_64 /src/ci/build-wheel-linux.sh ${{ matrix.python-version }}
#
# - name: Setup Python
# uses: actions/setup-python@v1
# with:
# python-version: ${{ matrix.python-version }}
#
# - name: Display Python version
# run: python -c "import sys; print(sys.version)"
# - name: Test
# shell: bash -l {0}
# run: |
# ./ci/test-wheel-linux.sh ${{ matrix.python-version }}
#
# - uses: actions/upload-artifact@v1
# with:
# name: manylinux-${{ matrix.python-version }}-whl
# path: wheelhouse
#
# windows-wheel:
# name: Win64 ${{ matrix.python-version }} Wheel
#
# runs-on: ${{ matrix.os }}
# strategy:
# matrix:
# os: ['windows-latest']
# python-version: ['3.6','3.7','3.8']
# sidx-version: ['1.9.3']
# fail-fast: true
#
# steps:
# - uses: actions/checkout@v2
# - uses: goanpeca/setup-miniconda@v1.1.2
# with:
# channels: conda-forge
# auto-update-conda: true
# python-version: ${{ matrix.python-version }}
# - name: Setup
# shell: bash -l {0}
# run: |
# conda install -c conda-forge compilers -y
# pip install cmake ninja
#
# - name: build
# shell: cmd /C CALL "{0}"
# run: |
# call .\ci\build-wheel.bat ${{ matrix.sidx-version }}
#
# - name: test
# shell: cmd /C CALL "{0}"
# run: |
# call .\ci\test-wheel.bat
#
# - uses: actions/upload-artifact@v1
# with:
# name: win64-${{matrix.python-version}}-whl
# path: dist
#
# osx-wheel:
# name: OSX ${{ matrix.python-version }} Wheel
#
# runs-on: ${{ matrix.os }}
# strategy:
# matrix:
# os: ['macos-latest']
# python-version: [3.6, 3.7, 3.8]
# fail-fast: true
#
# steps:
# - uses: actions/checkout@v2
# - name: Setup Python
# uses: actions/setup-python@v1
# with:
# python-version: ${{ matrix.python-version }}
#
# - name: Display Python version
# run: python -c "import sys; print(sys.version)"
#
# - name: Setup
# run: |
# python -m pip install cmake ninja
#
# - name: build
# run: |
# ./ci/build-wheel-osx.sh ${{ matrix.python-version }}
#
# - name: test
# run: |
# ./ci/test-wheel-osx.sh
#
# - uses: actions/upload-artifact@v1
# with:
# name: osx-${{matrix.python-version}}-whl
# path: wheels
#

docs:
name: Docs

runs-on: ubuntu-latest
strategy:
fail-fast: true
container: osgeo/proj-docs

steps:
- uses: actions/checkout@v2
- name: Run libspatialindex build
run: |
apt-get update -y
apt-get install -y -qq libspatialindex-dev
pip3 install --user .
- name: Print versions
shell: bash -l {0}
run: |
Expand Down Expand Up @@ -241,42 +134,6 @@ jobs:
export PATH=$PATH:/home/runner/.local/bin
python3 setup.py sdist

# - uses: actions/download-artifact@v1
# name: Linux 3.6 wheel
# with:
# name: manylinux-cp36-cp36m-whl
# path: dist
#
# - uses: actions/download-artifact@v1
# name: Linux 3.7 wheel
# with:
# name: manylinux-cp37-cp37m-whl
# path: dist
#
# - uses: actions/download-artifact@v1
# name: Linux 3.8 wheel
# with:
# name: manylinux-cp38-cp38-whl
# path: dist
#
# - uses: actions/download-artifact@v1
# name: Win64 3.6 wheel
# with:
# name: win64-3.6-wheel
# path: dist
#
# - uses: actions/download-artifact@v1
# name: Win64 3.7 wheel
# with:
# name: win64-3.7-wheel
# path: dist
#
# - uses: actions/download-artifact@v1
# name: Win64 3.8 wheel
# with:
# name: win64-3.8-wheel
# path: dist

- uses: pypa/gh-action-pypi-publish@master
name: Publish package
if: github.event_name == 'release' && github.event.action == 'published'
Expand Down
56 changes: 56 additions & 0 deletions .github/workflows/wheels.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
name: Build Wheels

on: [push, pull_request]

jobs:
build_wheels:
name: Build wheel on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
env:
CIBW_SKIP: pp* *-win32
CIBW_TEST_REQUIRES: pytest numpy
CIBW_TEST_COMMAND: "pytest -v {project}/tests"
# we are copying the shared libraries ourselves so skip magical copy
CIBW_REPAIR_WHEEL_COMMAND_MACOS: ""
CIBW_REPAIR_WHEEL_COMMAND_WINDOWS: ""
CIBW_BEFORE_BUILD_LINUX: "pip install cmake; bash {project}/ci/install_libspatialindex.bash"
strategy:
matrix:
os: [windows-latest, ubuntu-latest, macos-latest]
steps:
- uses: actions/checkout@v1
- uses: actions/setup-python@v1
name: Install Python
with:
python-version: '3.7'
- name: Install cibuildwheel
run: |
python -m pip install cibuildwheel==1.6.4
- name: Run MacOS Preinstall Build
if: startsWith(matrix.os, 'macos')
run: |
# provides sha256sum
brew install coreutils
pip install cmake
bash ci/install_libspatialindex.bash
- name: Run Windows Preinstall Build
if: startsWith(matrix.os, 'windows')
run: |
choco install vcpython27 -f -y
ci\install_libspatialindex.bat
- name: Build wheels
run: |
python -m cibuildwheel --output-dir wheelhouse
- uses: actions/upload-artifact@v1
with:
name: wheels
path: ./wheelhouse
- name: Upload To PyPi
env:
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
# TODO : remove `if false` statement after secrets are set in Github UI
if: false
run: |
pip install twine
twine upload ./wheelhouse/*
5 changes: 4 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,8 @@ Rtree
![Build](https://github.com/Toblerity/rtree/workflows/Build/badge.svg)
[![PyPI version](https://badge.fury.io/py/Rtree.svg)](https://badge.fury.io/py/Rtree)

Python bindings for libspatialindex 1.8.3.
RTree is a Python package with bindings for [libspatialindex](https://github.com/libspatialindex/libspatialindex). Wheels are available for most major platforms, and `rtree` with bundled `libspatialindex` can be installed via pip:
```
pip install rtree
```

Loading