Skip to content

build multi-platform #26

build multi-platform

build multi-platform #26

name: build multi-platform
on:
workflow_dispatch:
jobs:
job_1:
name: ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [windows-latest, ubuntu-latest, macos-latest]
#exclude:
# - os: ubuntu-latest
# - os: macos-latest
steps:
- name: git checkout
uses: actions/checkout@v4
- name: build non-windows
if: runner.os != 'Windows'
run: |
eval "$(conda shell.bash activate)"
conda install -c conda-forge -y pyyaml jinja2 requests ninja
python setup.py -n all
- name: build windows
if: runner.os == 'Windows'
env:
CC: cl
run: |
#gmo -listavailable vssetup
#install-module vssetup
#get-vssetupinstance
#ls -l $env:programfiles/'Microsoft Visual Studio'
#ls $env:programfiles/'Microsoft Visual Studio' -recurse -filter *.DevShell.dll -file -name
#$env:path.split(';')
#ls -l $env:conda/shell/condabin
#ls -l env:
#echo "GITHUB_WORKSPACE: $env:GITHUB_WORKSPACE"
#echo "pwd: $(pwd)"
#iex "{$(& $env:CONDA/Scripts/conda shell.powershell activate)}"
& "$env:CONDA/shell/condabin/conda-hook.ps1"
& "$env:programfiles/Microsoft Visual Studio/2022/Enterprise/Common7/Tools/Launch-VsDevShell.ps1" -arch amd64
conda activate $env:CONDA
conda install -c conda-forge -y pyyaml jinja2 requests ninja
#cmake --help
echo "cmake version: $(cmake --version)"
ls -l env:
echo "GITHUB_WORKSPACE: $env:GITHUB_WORKSPACE"
pushd $env:GITHUB_WORKSPACE
echo 'running python setup.py ... in $(pwd)'
python setup.py -n all
- name: upload artifacts
uses: actions/upload-artifact@v4
#if: runner.os == 'macOS'
with:
retention-days: 3
path: |
dist/sortmerna*(Darwin|win64).7z
dist/sortmerna*(Darwin|Linux).sh
dist/sortmerna*(Darwin|Linux).tar.gz
dist/sortmerna*Linux.deb
#dist/sortmerna*Linux.sh
#dist/sortmerna*Linux.tar.gz
#dist/sortmerna*win64.7z