-
Notifications
You must be signed in to change notification settings - Fork 102
89 lines (76 loc) · 2.31 KB
/
emscripten-experimental.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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
name: 'Test Build (Emscripten Experimental)'
on:
workflow_dispatch:
workflow_run:
workflows: ["Test Builds"]
branches: [master]
types:
- completed
schedule:
# run every thursday at 10:00
- cron: '0 10 * * 4'
env:
MESON_VERSION: '0.63.3'
EM_VERSION: 'tot'
EM_CACHE_FOLDER: 'emsdk'
jobs:
emscripten-weekly-latest:
name: 'Emscripten'
if: "!contains(github.event.head_commit.message, '[skip ci]') && ${{ github.event.workflow_run.conclusion == 'success' }}"
runs-on: ubuntu-20.04
steps:
- name: Checkout Code
uses: actions/checkout@v4
with:
submodules: 'recursive'
- name: Install Python
uses: actions/setup-python@v5
with:
python-version: '3.9'
- name: Install Tools
run: >
sudo apt update || true
sudo apt install -y -qq
python3-docutils
python3-pip
git
pip install
meson==${{ env.MESON_VERSION }}
ninja
python-gnupg
zstandard
- name: Install Emscripten SDK
run: |
git clone https://github.com/emscripten-core/emsdk.git ${{ env.EM_CACHE_FOLDER }}
${{ env.EM_CACHE_FOLDER }}/emsdk install ${{ env.EM_VERSION }} || true
${{ env.EM_CACHE_FOLDER }}/emsdk activate ${{ env.EM_VERSION }}
- name: Verify Emscripten SDK
run: |
source ${{ env.EM_CACHE_FOLDER }}/emsdk_env.sh
emcc -v
tee misc/ci/emscripten-ephemeral-ci.ini <<EOF >/dev/null
[constants]
toolchain = '$(pwd)/${{ env.EM_CACHE_FOLDER }}/upstream/emscripten/'
EOF
- name: Configure
run: >
source ${{ env.EM_CACHE_FOLDER }}/emsdk_env.sh
meson setup build/
--cross-file misc/ci/common-options.ini
--cross-file misc/ci/forcefallback.ini
--cross-file misc/ci/emscripten-ephemeral-ci.ini
--cross-file misc/ci/emscripten-build.ini
--prefix=$(pwd)/build-test
meson configure
-Dbuild.cpp_std=gnu++14
build/
- name: Build
run: |
source ${{ env.EM_CACHE_FOLDER }}/emsdk_env.sh
meson compile tar -C build/ --verbose
ninja zip -C build/
- name: Upload Log
uses: actions/upload-artifact@v4
with:
name: taisei_emscripten_latest_build_log
path: build/meson-logs/meson-log.txt