0
Fork 0
mirror of https://github.com/penpot/penpot.git synced 2025-01-22 14:39:45 -05:00

Add render.wasm to the frontend build process

This commit is contained in:
Andrey Antukh 2024-11-14 11:02:22 +01:00
parent 5d4511fc6a
commit 1be204e22d
3 changed files with 8 additions and 1 deletions

View file

@ -20,6 +20,7 @@
"build:app:assets": "node ./scripts/build-app-assets.js",
"build:storybook": "yarn run build:storybook:assets && yarn run build:storybook:cljs && storybook build",
"build:storybook:assets": "node ./scripts/build-storybook-assets.js",
"build:wasm": "../render-wasm/build",
"build:storybook:cljs": "clojure -M:dev:shadow-cljs compile storybook",
"build:app:libs": "node ./scripts/build-libs.js",
"build:app:main": "clojure -M:dev:shadow-cljs release main worker",

View file

@ -20,6 +20,7 @@ yarn install || exit 1;
rm -rf resources/public;
rm -rf target/dist;
yarn run build:wasm || exit 1;
yarn run build:app:main --config-merge "{:release-version \"${CURRENT_HASH}-${TS}\"}" $EXTRA_PARAMS || exit 1
yarn run build:app:libs || exit 1;
yarn run build:app:assets || exit 1;

View file

@ -1,6 +1,11 @@
#!/usr/bin/env bash
export _BUILD_MODE=${1:-debug};
if [ "$NODE_ENV" = "production" ]; then
export _BUILD_MODE="release";
else
export _BUILD_MODE=${1:-debug};
fi
export EMSDK_QUIET=1
export EMCC_CFLAGS="--no-entry -s ERROR_ON_UNDEFINED_SYMBOLS=0 -s MAX_WEBGL_VERSION=2 -s MODULARIZE=1 -s EXPORT_NAME=createRustSkiaModule -s EXPORTED_RUNTIME_METHODS=GL -s ENVIRONMENT=web -s EXPORT_ES6=1 -sMODULARIZE"