diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 57079c5..88f88f2 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -12,6 +12,8 @@ env: TARGET_NAME: libgdsqlite VAR_PATH: .github/workflows/build_var.json SCONS_CACHE: ${{ github.workspace }}/.scons-cache/ + EM_VERSION: 3.1.39 + EM_CACHE_FOLDER: "emsdk-cache" jobs: matrix: @@ -65,6 +67,13 @@ jobs: ndk-version: r23c link-to-sdk: true + - name: Web dependencies + if: ${{ matrix.platform == 'web' }} + uses: mymindstorm/setup-emsdk@v13 + with: + version: ${{ env.EM_VERSION }} + actions-cache-folder: ${{ env.EM_CACHE_FOLDER }}-${{ matrix.target }} + # Setup scons, print python version and scons version info, so if anything is broken it won't run the build. - name: Configuring Python packages run: | diff --git a/.github/workflows/build_var.json b/.github/workflows/build_var.json index 6e18faa..613cdc0 100644 --- a/.github/workflows/build_var.json +++ b/.github/workflows/build_var.json @@ -50,6 +50,13 @@ "artifact-extension": "dylib", "flags": "arch=arm64", "cache-name": "ios-arm64" + }, + { + "name": "Web (wasm32)", + "os": "ubuntu-20.04", + "platform": "web", + "artifact-extension": "wasm", + "cache-name": "web-wasm32" } ] } \ No newline at end of file diff --git a/demo/addons/godot-sqlite/gdsqlite.gdextension b/demo/addons/godot-sqlite/gdsqlite.gdextension index 1a52792..e974acb 100644 --- a/demo/addons/godot-sqlite/gdsqlite.gdextension +++ b/demo/addons/godot-sqlite/gdsqlite.gdextension @@ -15,6 +15,8 @@ android.arm64 = "res://addons/godot-sqlite/bin/libgdsqlite.android.template_debu android.template_release.arm64 = "res://addons/godot-sqlite/bin/libgdsqlite.android.template_release.arm64.so" android.x86_64 = "res://addons/godot-sqlite/bin/libgdsqlite.android.template_debug.x86_64.so" android.template_release.x86_64 = "res://addons/godot-sqlite/bin/libgdsqlite.android.template_release.x86_64.so" +web.wasm32 = "res://addons/godot-sqlite/bin/libgdsqlite.web.template_debug.wasm32.wasm" +web.template_release.wasm32 = "res://addons/godot-sqlite/bin/libgdsqlite.web.template_release.wasm32.wasm" [dependencies] @@ -27,4 +29,6 @@ linux.template_release.x86_64 = {} android.arm64 = {} android.template_release.arm64 = {} android.x86_64 = {} -android.template_release.x86_64 = {} \ No newline at end of file +android.template_release.x86_64 = {} +web.wasm32 = {} +web.template_release.wasm32 = {} diff --git a/demo/project.godot b/demo/project.godot index c10a912..a35a784 100644 --- a/demo/project.godot +++ b/demo/project.godot @@ -12,7 +12,7 @@ config_version=5 config/name="SQLite Demo" run/main_scene="res://Main.tscn" -config/features=PackedStringArray("4.1") +config/features=PackedStringArray("4.2") config/icon="res://icon.png" [debug]