From 35f1bc7c785d3ac1f2ad658f220f953548231888 Mon Sep 17 00:00:00 2001 From: Andrew Sazonov Date: Fri, 19 Jul 2024 13:40:46 +0200 Subject: [PATCH] Add CI to build wasm --- .github/workflows/wasm.yml | 44 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100644 .github/workflows/wasm.yml diff --git a/.github/workflows/wasm.yml b/.github/workflows/wasm.yml new file mode 100644 index 0000000..bd8a516 --- /dev/null +++ b/.github/workflows/wasm.yml @@ -0,0 +1,44 @@ +name: wasm + +on: + push: + #schedule: + # - cron: '*/120 8-18 * * *' # every 2 hours from 8:00 to 18:00 every day + +jobs: + build: # the first job + # current job matrix. if modified, remember to UPDATE the strategy in the next job + strategy: + fail-fast: false + matrix: + os: [ubuntu-24] + + runs-on: ${{ matrix.os }} + + timeout-minutes: 30 + + steps: # job steps + - name: Check-out repository + uses: actions/checkout@v4 + + - name: Install emsdk + shell: bash + run: | + git clone https://github.com/emscripten-core/emsdk.git + cd emsdk + git pull + ./emsdk install 3.1.50 # this version is needed for Qt 6.7 + ./emsdk activate 3.1.50 + + - name: Install Qt for WebAssembly + shell: bash + run: | + curl -L -O https://download.qt.io/official_releases/online_installers/qt-unified-linux-arm64-online.run + chmod u+x qt-unified-linux-x64-4.8.0-online.run + ./qt-unified-linux-x64-4.8.0-online.run \ + --root /home/runner/Qt \ + --accept-licenses \ + --accept-obligations \ + --default-answer \ + --confirm-command \ + install qt.qt6.672.wasm_singlethread qt.qt6.672.qt5compat