-
Notifications
You must be signed in to change notification settings - Fork 1
53 lines (50 loc) · 1.75 KB
/
release-matfrostmex.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
name: "Release MATFrost MEX binary."
on:
workflow_dispatch:
jobs:
build-mex-binary:
strategy:
matrix:
matlab-version: ['2021b', '2022a', '2022b', '2023a', '2023b'] #, '2024a']
runs-on: windows-latest
name: windows-R${{ matrix.matlab-version }}
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up MATLAB on Windows
uses: matlab-actions/setup-matlab@v2
with:
release: R${{ matrix.matlab-version }}
# cache: true
products: >
${{ contains(matrix.matlab-version, '2024') && 'MATLAB_Support_for_MinGW-w64_C/C++/Fortran_Compiler' || 'MATLAB_Support_for_MinGW-w64_C/C++_Compiler' }}
- name: Compile MEX binary
uses: matlab-actions/run-command@v2
with:
command: addpath("src/matfrostjuliacall"), matfrostmake("matfrostjuliacall_r${{ matrix.matlab-version }}")
- name: Upload artifacts
if: always()
uses: actions/upload-artifact@v4
with:
path: src/matfrostjuliacall/bin
name: matfrost-mex-win-r${{ matrix.matlab-version }}-x64
release-mex-binary:
needs: build-mex-binary
runs-on: ubuntu-latest
name: Release-MEX-Binary
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Download MEX artifacts
uses: actions/download-artifact@v4
with:
path: mexbinwin
merge-multiple: true
- name: Display structure of downloade MEX binaries.
run: ls -R mexbinwin
- name: Upload MEX binaries
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
tar -czvf mexbinwin.tar.gz mexbinwin
gh release create testmex mexbinwin.tar.gz