-
Notifications
You must be signed in to change notification settings - Fork 39
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Add scripts to be run inside a cibuildwheel docker image on both linux and macos which installs static versions of OpenBLAS (linux only), fftw, and suitesparse. Link our internal _libtoast extension to these static packages, which ensures consistency regardless of other shared libraries loaded by other packages. - Add a github workflow which tests pip wheel building daily, and preserves the wheels as artifacts which can be downloaded and tested as needed. This also runs the unit tests on the installed wheel packages (linux and macos, python 3.6-3.8). - Add a deployment workflow executed on git tags which uploads to pypi. this will likely need some testing during 2.3.7 tag preparation. - Cleanup package definitions in setup.py, version generation, and add a MANIFEST.in file to ensure that extra package files are bundled.
- Loading branch information
Showing
17 changed files
with
597 additions
and
46 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,110 @@ | ||
# Deploy tagged releases. | ||
|
||
name: Deploy Release | ||
|
||
on: | ||
push: | ||
tags: | ||
- '*' | ||
|
||
env: | ||
TWINE_USERNAME: __token__ | ||
TWINE_PASSWORD: ${{ secrets.TWINE_PASSWORD }} | ||
|
||
jobs: | ||
py36: | ||
name: Python 3.6 wheels on ${{ matrix.os }} | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
matrix: | ||
os: [ubuntu-latest, macos-latest] | ||
env: | ||
CIBW_BUILD: cp36-macosx_x86_64 cp36-manylinux_x86_64 | ||
CIBW_MANYLINUX_X86_64_IMAGE: manylinux2014 | ||
CIBW_MANYLINUX_I686_IMAGE: manylinux2014 | ||
CIBW_BUILD_VERBOSITY: 3 | ||
CIBW_ENVIRONMENT_LINUX: "TOAST_STATIC_DEPS=1 TOAST_BUILD_BLAS_LIBRARIES='-lopenblas -fopenmp -lm -lgfortran' TOAST_BUILD_LAPACK_LIBRARIES='-lopenblas -fopenmp -lm -lgfortran'" | ||
CIBW_ENVIRONMENT_MACOS: "TOAST_STATIC_DEPS=1" | ||
CIBW_BEFORE_BUILD_LINUX: ./wheels/install_deps_linux.sh | ||
CIBW_BEFORE_BUILD_MACOS: ./wheels/install_deps_osx.sh | ||
CIBW_BEFORE_TEST: echo "" >/dev/null | ||
CIBW_TEST_COMMAND: export OMP_NUM_THREADS=2; python -c 'import toast.tests; toast.tests.run()' | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/setup-python@v2 | ||
name: Install Python | ||
with: | ||
python-version: '3.7' | ||
- name: Install cibuildwheel | ||
run: | | ||
python -m pip install twine cibuildwheel==1.4.2 | ||
- name: Build wheel | ||
run: | | ||
python -m cibuildwheel --output-dir wheelhouse | ||
- name: Upload to PyPI | ||
run: | | ||
python -m twine upload wheelhouse/toast*.whl | ||
py37: | ||
name: Python 3.7 wheels on ${{ matrix.os }} | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
matrix: | ||
os: [ubuntu-latest, macos-latest] | ||
env: | ||
CIBW_BUILD: cp37-macosx_x86_64 cp37-manylinux_x86_64 | ||
CIBW_MANYLINUX_X86_64_IMAGE: manylinux2014 | ||
CIBW_MANYLINUX_I686_IMAGE: manylinux2014 | ||
CIBW_BUILD_VERBOSITY: 3 | ||
CIBW_ENVIRONMENT_LINUX: "TOAST_STATIC_DEPS=1 TOAST_BUILD_BLAS_LIBRARIES='-lopenblas -fopenmp -lm -lgfortran' TOAST_BUILD_LAPACK_LIBRARIES='-lopenblas -fopenmp -lm -lgfortran'" | ||
CIBW_ENVIRONMENT_MACOS: "TOAST_STATIC_DEPS=1" | ||
CIBW_BEFORE_BUILD_LINUX: ./wheels/install_deps_linux.sh | ||
CIBW_BEFORE_BUILD_MACOS: ./wheels/install_deps_osx.sh | ||
CIBW_BEFORE_TEST: echo "" >/dev/null | ||
CIBW_TEST_COMMAND: export OMP_NUM_THREADS=2; python -c 'import toast.tests; toast.tests.run()' | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/setup-python@v2 | ||
name: Install Python | ||
with: | ||
python-version: '3.7' | ||
- name: Install cibuildwheel | ||
run: | | ||
python -m pip install twine cibuildwheel==1.4.2 | ||
- name: Build wheel | ||
run: | | ||
python -m cibuildwheel --output-dir wheelhouse | ||
- name: Upload to PyPI | ||
run: | | ||
python -m twine upload wheelhouse/toast*.whl | ||
py38: | ||
name: Python 3.8 wheels on ${{ matrix.os }} | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
matrix: | ||
os: [ubuntu-latest, macos-latest] | ||
env: | ||
CIBW_BUILD: cp38-macosx_x86_64 cp38-manylinux_x86_64 | ||
CIBW_MANYLINUX_X86_64_IMAGE: manylinux2014 | ||
CIBW_MANYLINUX_I686_IMAGE: manylinux2014 | ||
CIBW_BUILD_VERBOSITY: 3 | ||
CIBW_ENVIRONMENT_LINUX: "TOAST_STATIC_DEPS=1 TOAST_BUILD_BLAS_LIBRARIES='-lopenblas -fopenmp -lm -lgfortran' TOAST_BUILD_LAPACK_LIBRARIES='-lopenblas -fopenmp -lm -lgfortran'" | ||
CIBW_ENVIRONMENT_MACOS: "TOAST_STATIC_DEPS=1" | ||
CIBW_BEFORE_BUILD_LINUX: ./wheels/install_deps_linux.sh | ||
CIBW_BEFORE_BUILD_MACOS: ./wheels/install_deps_osx.sh | ||
CIBW_BEFORE_TEST: echo "" >/dev/null | ||
CIBW_TEST_COMMAND: export OMP_NUM_THREADS=2; python -c 'import toast.tests; toast.tests.run()' | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/setup-python@v2 | ||
name: Install Python | ||
with: | ||
python-version: '3.7' | ||
- name: Install cibuildwheel | ||
run: | | ||
python -m pip install twine cibuildwheel==1.4.2 | ||
- name: Build wheel | ||
run: | | ||
python -m cibuildwheel --output-dir wheelhouse | ||
- name: Upload to PyPI | ||
run: | | ||
python -m twine upload wheelhouse/toast*.whl |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,115 @@ | ||
|
||
name: Test Binary Wheels | ||
|
||
# Uncomment here for testing and comment out schedule below. | ||
# on: | ||
# push: | ||
# branches: [ master ] | ||
# pull_request: | ||
# branches: [ master ] | ||
|
||
# Uncomment here for production and comment out push / PR above. | ||
on: | ||
schedule: | ||
- cron: '0 4 * * *' | ||
|
||
jobs: | ||
py36: | ||
name: Python 3.6 wheels on ${{ matrix.os }} | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
matrix: | ||
os: [ubuntu-latest, macos-latest] | ||
env: | ||
CIBW_BUILD: cp36-macosx_x86_64 cp36-manylinux_x86_64 | ||
CIBW_MANYLINUX_X86_64_IMAGE: manylinux2014 | ||
CIBW_MANYLINUX_I686_IMAGE: manylinux2014 | ||
CIBW_BUILD_VERBOSITY: 3 | ||
CIBW_ENVIRONMENT_LINUX: "TOAST_STATIC_DEPS=1 TOAST_BUILD_BLAS_LIBRARIES='-lopenblas -fopenmp -lm -lgfortran' TOAST_BUILD_LAPACK_LIBRARIES='-lopenblas -fopenmp -lm -lgfortran'" | ||
CIBW_ENVIRONMENT_MACOS: "TOAST_STATIC_DEPS=1" | ||
CIBW_BEFORE_BUILD_LINUX: ./wheels/install_deps_linux.sh | ||
CIBW_BEFORE_BUILD_MACOS: ./wheels/install_deps_osx.sh | ||
CIBW_BEFORE_TEST: echo "" >/dev/null | ||
CIBW_TEST_COMMAND: export OMP_NUM_THREADS=2; python -c 'import toast.tests; toast.tests.run()' | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/setup-python@v2 | ||
name: Install Python | ||
with: | ||
python-version: '3.7' | ||
- name: Install cibuildwheel | ||
run: | | ||
python -m pip install cibuildwheel==1.4.2 | ||
- name: Build wheel | ||
run: | | ||
python -m cibuildwheel --output-dir wheelhouse | ||
- uses: actions/upload-artifact@v2 | ||
with: | ||
name: wheels | ||
path: ./wheelhouse | ||
py37: | ||
name: Python 3.7 wheels on ${{ matrix.os }} | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
matrix: | ||
os: [ubuntu-latest, macos-latest] | ||
env: | ||
CIBW_BUILD: cp37-macosx_x86_64 cp37-manylinux_x86_64 | ||
CIBW_MANYLINUX_X86_64_IMAGE: manylinux2014 | ||
CIBW_MANYLINUX_I686_IMAGE: manylinux2014 | ||
CIBW_BUILD_VERBOSITY: 3 | ||
CIBW_ENVIRONMENT_LINUX: "TOAST_STATIC_DEPS=1 TOAST_BUILD_BLAS_LIBRARIES='-lopenblas -fopenmp -lm -lgfortran' TOAST_BUILD_LAPACK_LIBRARIES='-lopenblas -fopenmp -lm -lgfortran'" | ||
CIBW_ENVIRONMENT_MACOS: "TOAST_STATIC_DEPS=1" | ||
CIBW_BEFORE_BUILD_LINUX: ./wheels/install_deps_linux.sh | ||
CIBW_BEFORE_BUILD_MACOS: ./wheels/install_deps_osx.sh | ||
CIBW_BEFORE_TEST: echo "" >/dev/null | ||
CIBW_TEST_COMMAND: export OMP_NUM_THREADS=2; python -c 'import toast.tests; toast.tests.run()' | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/setup-python@v2 | ||
name: Install Python | ||
with: | ||
python-version: '3.7' | ||
- name: Install cibuildwheel | ||
run: | | ||
python -m pip install cibuildwheel==1.4.2 | ||
- name: Build wheel | ||
run: | | ||
python -m cibuildwheel --output-dir wheelhouse | ||
- uses: actions/upload-artifact@v2 | ||
with: | ||
name: wheels | ||
path: ./wheelhouse | ||
py38: | ||
name: Python 3.8 wheels on ${{ matrix.os }} | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
matrix: | ||
os: [ubuntu-latest, macos-latest] | ||
env: | ||
CIBW_BUILD: cp38-macosx_x86_64 cp38-manylinux_x86_64 | ||
CIBW_MANYLINUX_X86_64_IMAGE: manylinux2014 | ||
CIBW_MANYLINUX_I686_IMAGE: manylinux2014 | ||
CIBW_BUILD_VERBOSITY: 3 | ||
CIBW_ENVIRONMENT_LINUX: "TOAST_STATIC_DEPS=1 TOAST_BUILD_BLAS_LIBRARIES='-lopenblas -fopenmp -lm -lgfortran' TOAST_BUILD_LAPACK_LIBRARIES='-lopenblas -fopenmp -lm -lgfortran'" | ||
CIBW_ENVIRONMENT_MACOS: "TOAST_STATIC_DEPS=1" | ||
CIBW_BEFORE_BUILD_LINUX: ./wheels/install_deps_linux.sh | ||
CIBW_BEFORE_BUILD_MACOS: ./wheels/install_deps_osx.sh | ||
CIBW_BEFORE_TEST: echo "" >/dev/null | ||
CIBW_TEST_COMMAND: export OMP_NUM_THREADS=2; python -c 'import toast.tests; toast.tests.run()' | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/setup-python@v2 | ||
name: Install Python | ||
with: | ||
python-version: '3.7' | ||
- name: Install cibuildwheel | ||
run: | | ||
python -m pip install cibuildwheel==1.4.2 | ||
- name: Build wheel | ||
run: | | ||
python -m cibuildwheel --output-dir wheelhouse | ||
- uses: actions/upload-artifact@v2 | ||
with: | ||
name: wheels | ||
path: ./wheelhouse |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
include README.md | ||
include AUTHORS | ||
include LICENSE | ||
include src | ||
include CMakeLists.txt | ||
include tutorial | ||
include example | ||
include platforms | ||
include cmake | ||
include docs |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.