diff options
author | MoustaphaSaad <moustapha.saad.abdelhamed@gmail.com> | 2024-05-31 21:29:14 +0300 |
---|---|---|
committer | Theo Buehler <tb@openbsd.org> | 2024-06-19 14:06:09 +0200 |
commit | 64d11fcf11b70edb48f75f55942e8a4c7856bf7a (patch) | |
tree | 7e4d858668c3d46ec3dc2ab43aaa94bbb66429ef /.github | |
parent | 08d0f580b2313aaa73eeca14134647336d707bb9 (diff) | |
download | portable-64d11fcf11b70edb48f75f55942e8a4c7856bf7a.tar.gz portable-64d11fcf11b70edb48f75f55942e8a4c7856bf7a.tar.bz2 portable-64d11fcf11b70edb48f75f55942e8a4c7856bf7a.zip |
add initial Emscripten CI workflow
Diffstat (limited to '.github')
-rw-r--r-- | .github/workflows/emscripten.yml | 68 |
1 files changed, 68 insertions, 0 deletions
diff --git a/.github/workflows/emscripten.yml b/.github/workflows/emscripten.yml new file mode 100644 index 0000000..c4e896f --- /dev/null +++ b/.github/workflows/emscripten.yml | |||
@@ -0,0 +1,68 @@ | |||
1 | # GitHub Actions workflow to run tests on Linux. | ||
2 | name: "Emscripten" | ||
3 | |||
4 | on: | ||
5 | push: {} | ||
6 | pull_request: {} | ||
7 | schedule: | ||
8 | - cron: "0 0 * * *" # At 00:00 daily. | ||
9 | |||
10 | concurrency: | ||
11 | group: "${{ github.workflow }}-${{ github.ref }}" | ||
12 | cancel-in-progress: true | ||
13 | |||
14 | jobs: | ||
15 | test: | ||
16 | name: "Emscripten" | ||
17 | runs-on: "ubuntu-latest" | ||
18 | if: ${{ github.repository_owner == 'libressl' || github.event_name != 'schedule' }} | ||
19 | permissions: | ||
20 | contents: read | ||
21 | steps: | ||
22 | - name: "Checkout repository" | ||
23 | uses: actions/checkout@v4 | ||
24 | |||
25 | - name: "Setup emsdk" | ||
26 | uses: mymindstorm/setup-emsdk@v14 | ||
27 | with: | ||
28 | version: 3.1.60 | ||
29 | |||
30 | - name: "Prepare repository" | ||
31 | run: "./autogen.sh" | ||
32 | |||
33 | - name: "Configure CMake" | ||
34 | run: cmake -Bbuild -DCMAKE_CROSSCOMPILING_EMULATOR=$EMSDK/node/18.20.3_64bit/bin/node -DCMAKE_TOOLCHAIN_FILE=$EMSDK/upstream/emscripten/cmake/Modules/Platform/Emscripten.cmake -DENABLE_ASM=OFF | ||
35 | |||
36 | - name: "Build" | ||
37 | run: cmake --build build --config Release | ||
38 | |||
39 | - name: "Test" | ||
40 | run: ctest --test-dir build -C Release --output-on-failure | ||
41 | |||
42 | # Test ASAN with and without ASM enabled. | ||
43 | test-asan: | ||
44 | name: "ASAN (no-asm)" | ||
45 | runs-on: "ubuntu-latest" | ||
46 | if: ${{ github.repository_owner == 'libressl' || github.event_name != 'schedule' }} | ||
47 | permissions: | ||
48 | contents: read | ||
49 | steps: | ||
50 | - name: "Checkout repository" | ||
51 | uses: actions/checkout@v4 | ||
52 | |||
53 | - name: "Setup emsdk" | ||
54 | uses: mymindstorm/setup-emsdk@v14 | ||
55 | with: | ||
56 | version: 3.1.60 | ||
57 | |||
58 | - name: "Prepare repository" | ||
59 | run: "./autogen.sh" | ||
60 | |||
61 | - name: "Configure CMake" | ||
62 | run: cmake -Bbuild -DCMAKE_CROSSCOMPILING_EMULATOR=$EMSDK/node/18.20.3_64bit/bin/node -DCMAKE_TOOLCHAIN_FILE=$EMSDK/upstream/emscripten/cmake/Modules/Platform/Emscripten.cmake -DENABLE_ASM=OFF | ||
63 | |||
64 | - name: "Build" | ||
65 | run: cmake --build build --config Release | ||
66 | |||
67 | - name: "Test" | ||
68 | run: ctest --test-dir build -C Release --output-on-failure | ||