[CI] Also test Python on Ubuntu and Windows #256
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
name: Build Conda Packages (rapidgzip) | |
on: | |
push: | |
branches: 'master' | |
jobs: | |
Build-Conda: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
# Building on MacOS fails for some reason with: | |
# ld: unsupported tapi file type '!tapi-tbd' in YAML file '/Applications/Xcode_14.2.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/lib/libSystem.tbd' for architecture x86_64 | |
# The only real difference to indexed_bzip2 is the NASM build requirement, so that might be the problem? | |
# Disabling ISA-L does not help. It might be an issue with zlib then? | |
os: [ubuntu-latest, windows-latest] | |
env: | |
MACOSX_DEPLOYMENT_TARGET: "10.14" | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
submodules: recursive | |
- uses: conda-incubator/setup-miniconda@v3 | |
with: | |
auto-update-conda: true | |
- name: Fix macOS CommandLineTools Bug | |
if: matrix.os == 'macos-latest' | |
shell: bash | |
run: | | |
# See test.yml workflow for explanation but in short: conda build only works with the older SDK installed. | |
wget https://github.com/phracker/MacOSX-SDKs/releases/download/10.13/MacOSX10.9.sdk.tar.xz | |
tar -xf MacOSX10.9.sdk.tar.xz | |
cat <<EOF >> conda/conda_build_config.yaml | |
CONDA_BUILD_SYSROOT: | |
- $PWD/MacOSX10.9.sdk | |
EOF | |
- name: Build Conda Packages | |
# Bash shells do not use ~/.profile or ~/.bashrc so these shells need to be explicitely declared as shell: | |
# bash -l {0} on steps that need to be properly activated | |
shell: bash -l {0} | |
# Should only upload on tags anyway!? | |
#env: | |
# ANACONDA_TOKEN: ${{ secrets.ANACONDA_TOKEN }} | |
working-directory: python/rapidgzip/conda | |
run: | | |
conda install conda conda-build anaconda-client conda-verify packaging | |
conda config --add channels conda-forge | |
conda config --set report_errors false | |
conda config --set anaconda_upload no | |
python3 -m pip install --user build | |
python3 -m build -o . --sdist .. | |
mv rapidgzip-*.tar* src.tar | |
#conda build . | |
#conda build --token "$ANACONDA_TOKEN" . |