Make the dist bundle use consistent and cache-aware uris (#7911)

This commit is contained in:
Andrey Antukh
2025-12-09 08:05:28 +01:00
committed by GitHub
parent 81e0e4f222
commit d04fdb5fbd
18 changed files with 112 additions and 104 deletions

View File

@@ -1,11 +1,15 @@
#!/usr/bin/env bash
CURRENT_VERSION=${CURRENT_VERSION:-develop};
if [ "$NODE_ENV" = "production" ]; then
export _BUILD_MODE="release";
export BUILD_MODE="release";
else
export _BUILD_MODE=${1:-debug};
export BUILD_MODE=${1:-debug};
fi
BUILD_NAME="${BUILD_NAME:-render-wasm}"
# 256 MB of initial heap to perform less
# initial calls to memory grow.
EM_INITIAL_HEAP=$((256 * 1024 * 1024))
@@ -40,10 +44,10 @@ EMCC_CFLAGS="--no-entry \
export EM_CACHE="/tmp/emsdk_cache";
_CARGO_PARAMS="${@:2}";
CARGO_PARAMS="${@:2}";
if [ "$_BUILD_MODE" = "release" ]; then
_CARGO_PARAMS="--release $_CARGO_PARAMS"
if [ "$BUILD_MODE" = "release" ]; then
CARGO_PARAMS="--release $CARGO_PARAMS"
EMCC_CFLAGS="-Os $EMCC_CFLAGS"
else
# TODO: Extra parameters that could be good to look into:
@@ -54,5 +58,5 @@ else
fi
export EMCC_CFLAGS;
export _CARGO_PARAMS;
export CARGO_PARAMS;